sp_helptrigger (Transact-SQL)
Returns the type or types of DML triggers defined on the specified table for the current database.sp_helptrigger cannot be used with DDL triggers.Sorgu sistem saklı yordamları görünümü yerine katalog.
sp_helptrigger [ @tabname = ] 'table'
[ , [ @triggertype = ] 'type' ]
Bağımsız değişkenler
[ @tabname= ] 'table'
Is the name of the table in the current database for which to return trigger information.table is nvarchar(776), with no default.[ @triggertype= ] 'type'
Is the type of DML trigger to return information about.type is char(6), with a default of NULL, and can be one of these values.Değer
Açıklama
SİLME
DELETE Tetik bilgi verir.
EKLEME
INSERT Tetikleyici bilgileri döndürür.
GÜNCELLEŞTİRME
UPDATE tetikleyicisi bilgileri döndürür.
Dönüş Kodu Değerleri
0 (başarılı) veya 1 (hata)
Sonuç Kümeleri
Aşağıdaki tabloda, sonuç kümesinde içerdiği bilgiler gösterilmektedir.
Sütun adı |
Veri türü |
Açıklama |
---|---|---|
trigger_name |
sysname |
Tetikleyici adı. |
trigger_owner |
sysname |
Tetikleyici tanımlandığı tablo sahibinin adı. |
isupdate |
int |
1 UPDATE tetikleyicisi = 0 Bir UPDATE tetikleyicisi = |
isdelete |
int |
1 DELETE Tetik = 0 DELETE Tetik = |
isinsert |
int |
1 INSERT tetikleyicisi = 0 Bir INSERT tetikleyicisi = |
isafter |
int |
1 Tetikleyici SONRA = 0 Bir AFTER tetikleyicisi = |
isinsteadof |
int |
1 Tetikleyici ıNSTEAD OF = 0 Bir INSTEAD OF tetikleyicisi = |
trigger_schema |
sysname |
Tetikleyici ait olduğu şema adı. |
Örnekler
Aşağıdaki örnek yürütür. sp_helptrigger the trigger(s) hakkında bilgi üretmeye Person.Contact TABLO.
USE AdventureWorks;
GO
EXEC sp_helptrigger 'Person.Contact'