Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> Re: DISTINCT in UNION

Re: DISTINCT in UNION

From: Jonathan Lewis <jonathan_at_jlcomp.demon.co.uk>
Date: Thu, 9 Nov 2000 20:06:38 -0000
Message-ID: <973797267.10070.1.nnrp-13.9e984b29@news.demon.co.uk>

If this is really happening, it's a bug.

UNION does a SORT (UNIQUE)
prior to output.

As an alternative - are you sure that the numbers ARE duplicated, is it possible
that a 3GL has caused differences at
(say) the 36th sig. fig. that are not
appearing in the default output ?

--

Jonathan Lewis
Yet another Oracle-related web site:  http://www.jlcomp.demon.co.uk

Practical Oracle 8i:  Building Efficient Databases

Publishers:                 Addison Wesley Longman
Book bound date:     8th Dec 2000
See a first review at:
http://www.ixora.com.au/resources/index.htm#practical_8i

shaikh74_at_my-deja.com wrote in message <8uems6$3ra$1_at_nnrp1.deja.com>...

>Hello Deja community:
>Here is something to challenge your mind,
>
>SELECT DISTINCT INV.INVEST_SEQ_NBR,
>FROM INVESTIGATION INV
>UNION
>SELECT DISTINCT INV.INVEST_SEQ_NBR,
>FROM INVESTIGATION INV
>
>I am getting duplicate rows back with same INV.INVEST_SEQ_NBR. I was
>wondering how can I apply DISTINCT on the result set returned by
>UNION. As you can see, in above query DISTINCT is appllied to each
>query but on the final result set. Your assitance is appreiciated.
>Send reply to shaikh74_at_visto.com
>Thanks
>Asad
>
>
>Sent via Deja.com http://www.deja.com/
>Before you buy.
Received on Thu Nov 09 2000 - 14:06:38 CST

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US