日期:2014-05-18 浏览次数:20491 次
create table t5 ( id int identity(1,1), a int ) insert into t5 values(0) insert into t5 values(2) insert into t5 values(3) create trigger tri_t_d on t5 instead of delete as declare @i int select @i=id from deleted update t5 set a=1 where id=@i --------------------------------------- 执行这个看看: delete from t5 where id=1 select * from t5