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 -> delete duplicate record

delete duplicate record

From: ÀåÇöÈ£ <h2chang_at_chollian.net>
Date: Tue, 26 Oct 1999 15:54:34 GMT
Message-ID: <_8kR3.822$%m2.54202@news2.bora.net>


hi all
if you have a unique key with col1 + col1, you can use following sql.

delete from table_name a
where a.rowid > (select min(b.rowid) from table_name b

                           where b.col1  =  a.col1
                               and b.col2 = a.col2 )

if you have any questions, feel free let me know. bye
from hhchang
mail : h2chang_at_chollian.net Received on Tue Oct 26 1999 - 10:54:34 CDT

Original text of this message

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