标签:tar blog and log enabled 情况 code trigger sqlserver
本文转自:http://blog.csdn.net/miqi770/article/details/48708199
SELECT t.name AS TableName, tr.name AS TriggerName, CASE WHEN 1=OBJECTPROPERTY(tr.id, ‘ExecIsTriggerDisabled‘) THEN ‘Disabled‘ ELSE ‘Enabled‘ END Status FROM sysobjects t INNER JOIN sysobjects tr ON t.id = tr.parent_obj WHERE ( t.xtype = ‘U‘ OR t.XType = ‘V‘) AND ( tr.xtype = ‘TR‘) ORDER BY t.name, tr.name
本文转自:http://www.cnblogs.com/davidhou/p/5846914.html
--查看当前库中所有的触发器:
SELECT * FROM Sysobjects WHERE xtype = ‘TR‘
--查看当前库中所有的触发器和与之相对应的表:
SELECT tb2.name AS tableName,tb1.name AS triggerName FROM Sysobjects tb1 JOIN Sysobjects tb2 ON tb1.parent_obj=tb2.id WHERE tb1.type=‘TR‘
--显示触发器的定义:
EXEC sp_helptext ‘触发器名‘
--查看触发器的有关信息:
EXEC sp_help ‘触发器名‘
--查看表中的触发器类型:
EXEC sp_helptrigger ‘表名‘
[转] sqlserver 中查看trigger的disabled/enabled情况
标签:tar blog and log enabled 情况 code trigger sqlserver
原文地址:http://www.cnblogs.com/freeliver54/p/7379800.html