对于具有“INSTEAD OF”触发器的表的Insert语句会导致无限的“替代”,插入“循环执行”?
例如:
CREATE TRIGGER setDescToUpper ON part_numbers INSTEAD OF INSERT AS BEGIN INSERT INTO part_numbers ( colA,colB,part_description ) SELECT colA,UPPER(part_description) ) FROM INSERTED END GO
“代替”触发器中的insert语句会导致循环吗?
我不想禁用递归触发器.
我需要暂时禁用触发器吗?
资料来源:SQL Server – after insert trigger – update another column in the same table