数据去重
作者:互联网
delete from xx where smokevehicleid not in (
select t.max_id from
(select max(smokevehicleid) as max_id from xxx group by smokeno) as t
);
delete from xxx a where a.SmokeNo in (select SmokeNo from xxx where smokevehicleid not in (
select t.max_id from
(select max(smokevehicleid) as max_id from xxx group by smokeno) as t
))
标签:max,xxx,smokevehicleid,where,数据,id,select 来源: https://www.cnblogs.com/luoguixin/p/16424300.html