34,587
社区成员
发帖
与我相关
我的任务
分享
select *
from tb a
where 1=1
and not exists (select 1 from tb b where b.pno=a.pno and b.price<a.price)
and pno=@pno
select * from material where price in(select min(price) from material where pno='A001') where pno='A001'
select *
from tb t
where pno='a001' and not exists(select * from tb where t.pno=pno and t.price<price )