SQL去重取ID最大值

select * from bas_app a
where not exists
(
select 1 from bas_app 
where AppName = a.AppName and id > a.id
)

猜你喜欢

转载自blog.csdn.net/neo9781467/article/details/86591862