Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.server -> Re: Deleting duplicate records
Hi
delete from dupl_table t1
where exists (select null
from dupl_table t2 where t1.column_1 = t2.column_1 and t1.column_2 = t2.column_2 .... and t1.rowid < t2.rowid)/
This should do the trick.
Rgds,
Steinar Heggelund
amit srivastava (amit_at_intrex.net) wrote:
: How can one delete all the records and leave one, if you have more than
: 2 duplicates for certain records in a table? , using SQL.
Received on Thu Feb 27 1997 - 00:00:00 CST