我想在以查询的基础上加一这么一个条件怎么加呀
我想在以查询的基础上加一这么一个条件怎么加呀
想加的条件如下:
b.zbxh(序号)相同的,同一个h.zlcc(质量层次),品种h.brand>=3种的所有记录显示出来
查询语句如下:
select b.zbxh,d.chinaname,d.chinaspec,e.unitname,h.brand,h.Produce_Factory,
h.Minpacking,h.zlcc,h.qtsm,h.Elucidation,g.Enterprisename,a.bidid,c.auditing,
c.id,d.typeid, c.jionproduct, a.drexpertid, h.Newprice, c.lastprice, c.price
from
drexpert_type a ,
bid_product b ,
user_product c ,
product_basic d ,
unit e ,
bid_user f,
EnterpriseBasicInfor g ,
product_qt h,[user] i
where
g.userid=i.userid
and a.bidid=b.bidid and c.bidid=b.bidid
and c.productqtID=h.id and d.id=h.basicid and b.product_basicid=d.id and
d.typeid=a.bid_typeid and d.unitid= e.id and f.bidid = b.bidid AND c.userid = f.id and
f.userid=i.userid and a.bidid=63 and c.auditing=1 and f.usertype=1 and a.drexpertid=88