orcale删除数据库中重复数据

delete from EM_EXPERT
 
  where MPHONE in (select MPHONE from EM_EXPERT group by MPHONE
 
  having count(MPHONE) > 1)
 
  and rowid not in (select min(rowid) from EM_EXPERT group by MPHONE having count(MPHONE)>1)

猜你喜欢

转载自amosjiayou.iteye.com/blog/2065995