删除重复记录保留1条SM7313|重复是指字段相同,例如wlid、nfyf 和ckid3个字段相同
wlid、nfyf 和ckid都相同
delete from sm_AQKC_tb where id in (select id from (select t.id, t.wlid,t.nfyf,t.ckid,ROW_NUMBER() OVER (PARTITION BY wlid, nfyf,ckid ORDER BY id) as rn FROM sm_AQKC_tb t where NFYF='202412') where rn>1); commit;