create trigger TR_MasterTable_Update on MasterTable after update as if update ([Type])--当Type字段被更新时,才会触发此触发器 insert into MasterLogTable select Id ,(Case [Type] when 1 then 'Type1' when 2 then 'Type2' when 3 then 'Type3' when 4 then 'Type4' else 'TypeDefault' end) ,Name from inserted go