oracle 删除重复行

delete from t_productbilldetailvods nologging where detailbillid in (select detailbillid from t_productbilldetailvods group by detailbillid having count(detailbillid) > 1) and rowid not in (select min(rowid) from t_productbilldetailvods group by detailbillid having count(detailbillid) > 1);

你可能感兴趣的:(oracle,delete)