1、查找表中多余的重復(fù)記錄,重復(fù)記錄是根據(jù)單個字段(peopleId)來判斷 復(fù)制代碼代碼如下: select * from content where 標題 in (select 標題 from content group by 標題 having count (標題) > 1) 2、刪除表中多余的重復(fù)記錄,重復(fù)記錄是根據(jù)單個字段(peopleId)來判斷,只留有rowid最小的記錄 復(fù)制代碼代碼如下: delete from content where 標題 in (select 標題 from people group by 標題 having count (標題) > 1) )>1) |
|