Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.tools -> Re: HELP! How to identify and remove duplicate records
Easier in Sql*plus.
Determine primary key.
Select pkcolumn [,..pkColn], count(*)
from table
group by pkcolumn1[,..pkColn]
having count(*) > 1
these are the dupes for the pk.
Remove them with a delete statement.
Or, alter the table, applying the pk and exceptions into the exceptions
table.
Review exceptions vs. raw data by joining by exceptions.row_id to main
table.
Delete records, then enable primary key.
"Ho" <kowho_at_singnet.com.sg> wrote in message
news:8u266q$bo2$2_at_coco.singnet.com.sg...
> How to identify and remove duplicate records using PL/SQL ?
>
> Many thanks for your help in advance.
>
>
>
Received on Sat Nov 04 2000 - 20:12:20 CST
![]() |
![]() |