删除oracle重复值

例子 表为:bdc_fj 主键为:id

sql语句
DELETE from bdc_fj WHERE (id) IN ( SELECT id FROM  bdc_fj GROUP BY id HAVING COUNT(id) > 1) AND ROWID NOT IN (SELECT MIN(ROWID) FROM  bdc_fj GROUP BY id HAVING COUNT(*) > 1);

你可能感兴趣的:(删除oracle重复值)