摘要:
删除重复记录Delete from tablename where id not in (select max(id) from tablename group by col1,col2,...)两张关联表,删除主表中已经在副表中没有的信息 delete from table1 where not exists ( select * from table2 where table1.field1=table2.field1 )delete from sns_message where not exists ( select * from sns_user where sns_user.uid= 阅读全文