select * from t_xs1500 where xh in (select xh from t_xs1500  where kclbm='值' group by xh having sum(xh)<7.2);

解决方案 »

  1.   

    应该修改一下:
    select * from t_xs1500 where xh in (select xh from t_xs1500  where kclbm='值' and fslkscj >= 60 group by xh having sum(xh)<7.2);
      

  2.   

    select  *  from  t_xs1500  where  xh  in  (select  xh  from  t_xs1500    where  kclbm='值'  and  fslkscj    >=  60  group  by  xh  having  sum(xh)  <7.2)
    union
    select * from t_xs1500 where xh not in (select xh from  t_xs1500  where kclbm='值');