标签:
update YF_MZFYZD set jjje=tbl.jjje from (select a.xh,sum(b.jjje) jjje from YF_MZFYZD a(nolock),YF_MZFYMX b(nolock)
where a.xh=b.fyxh group by a.xh) tbl,YF_MZFYZD x where tbl.xh=x.xh and isnull(x.jjje,0)=0
标签:
原文地址:http://www.cnblogs.com/kaiwanlin/p/4201064.html