多表连接批量更新。
UPDATE BOMT SET WASTAGE = '0.00' WHERE
CODE=(SELECT A.CODE FROM BOMT A LEFT JOIN PRO B ON A.CODE=B.CODE WHERE B.SERIES='D')
AND BOMNO=(SELECT A.BOMNO FROM BOMT A LEFT JOIN PRO B ON A.CODE=B.CODE WHERE B.SERIES='D')
------解决方案--------------------UPDATE BOMT SET WASTAGE = '0.00' WHERE exists (select 1 FROM BOMT A LEFT JOIN PRO B ON A.CODE=B.CODE WHERE B.SERIES='D' and A.CODE=code and A.BOMNO=BOMNO)
------解决方案--------------------update A set WASTAGE = '0.00' from BOMT A inner join PRO B ON A.CODE=B.CODE and WHERE B.SERIES='D'
------解决方案--------------------- -多个and,更新用left join没有意义吧
update A set WASTAGE = '0.00' from BOMT A inner join PRO B ON A.CODE=B.CODE WHERE B.SERIES='D'
------解决方案--------------------不知道你要实现什么结果,猜一个
update bomt set wastage='0.00' from bomt a join pro b
on a.code=b.code and b.series='d'