34,588
社区成员
发帖
与我相关
我的任务
分享
select a.fprice from a t1 inner join (select t1.fitemid, max(t1.FInterid) as finterid from a t1 group by t1.Fitemid order by t1.fitemid) t2 on t1.fitemid = t2.fitemid and t1.finterid = t2.finterid
select a.* from 表a a inner join (select max(FInterid) as maxf from 表a) b on a.finterid=b.maxf
select a.* from 表a a inner join (select max(FInterid) as maxf from 表a group by fitemid) b on a.finterid=b.maxf
select * from a t
where not exists(select 1 from a where t.fitemid=fitemid and t.FInterid<FInterid)