on
PU_AppVouchs
for
update
as
begin
update PU_AppVouchs set cDefine23=(select cInvCode,cWhCode, SUM (ItemId) as 汇总
from CurrentStock
where cWhCode='30'
GROUP BY cInvCode,ItemId,cWhCode)
from
CurrentStock,PU_AppVouchs,PU_AppVouch
where
PU_AppVouchs.cInvCode=CurrentStock.cInvCode
and
PU_AppVouchs.id=PU_AppVouch.id
and
CurrentStock.cWhCode='30'
end
问下这个触发语句应该怎么写才对。
[此贴子已经被作者于2019-9-10 09:02编辑过]