Sunil,
If there are multiple
duplicates for even a few SKU_Num values, you're doing multiple scans (full
table or full index) to get all the dups out. You might reconstruct the
SQL to not use a looping construct if there are lots of duplicate rows for each
SKU_Num
Delete From
FMS_Test
Where ( SKU_Num, RowID )
In
(
Select SKU_Num,
RowID
From
FMS_Test
Minus
Select SKU_Num, Max (
RowID )
From
FMS_Test
Group By
SKU_Num
) ;
Or keep the loop and add a
Commit right after the Delete statement - that will cut down on Rollback segment
usage.
Is there an index on the column
sku_num? It would probably help as well.
Jack
--------------------------------
|
- deleting duplicate records Sunil_Nookala
- Jack C. Applewhite