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 -> Finding Duplicates

Finding Duplicates

From: Rishi Pahuja <rishipahuja_at_rediffmail.com>
Date: 12 Feb 2005 11:46:53 -0800
Message-ID: <1108237613.526713.11620@f14g2000cwb.googlegroups.com>


Hello Everyone,

If any one can help me to write a query to delete duplicates from a table using 'analytic functions' it will be helpful.

All I want is to keep two records from a set of duplicates the most oldest and most recent one.

Eg:

1. X Y Z   10/2/2004
2. X Y Z   10/3/2004
3. X Y Z   10/4/2004

Output should be rows returned for 1 and last entry.

I want to achieve this with one query and not a PL-SQL code. Also the table I fire query will be 100M + records.

Thanks in advance.

Rishi Received on Sat Feb 12 2005 - 13:46:53 CST

Original text of this message

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