34,590
社区成员
发帖
与我相关
我的任务
分享
select * from tbl t where sort='删除' and time=(select max(time) from tbl where model=t.model)
select * from tbl a
where sort='删除' and time=(select max(time) from tbl where model=a.model
select * from tbl a
where sort='删除' and time=(select max(time) from tbl where model=a.model
select model,max(time) time
from tb
where sort = '删除'
group by model
select * from tbl a
where sort='删除'
and not exists (
select 1
from tbl
where model=a.model
and time>a.time
)