日期:2014-05-18  浏览次数:20525 次

修改一个触发器
我要修改一个已存在的触发器:
SQL code

use school
go

alter TRIGGER TR_CLASS_UPDATE
ON CLASS for insert,UPDATE
AS

 
运行后报错:cannot alter trigger 'TR_CLASS_UPDATE'on CLASS because this trigger
doesnot belong to this object.这是因为指定的库不对么?

------解决方案--------------------
应该是指定的库不对吧。
------解决方案--------------------
SQL code

select * from sysobjects where id = (
select parent_obj from sysobjects where xtype = 'TR' and id = object_id('你的触发器名')
)