TriggerAction Enum
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
The TriggerAction enumeration is used by the SqlTriggerContext class to indicate what action fired the trigger.
public enum class TriggerAction
public enum TriggerAction
type TriggerAction =
Public Enum TriggerAction
- Inheritance
-
TriggerAction
Fields
Name | Value | Description |
---|---|---|
Invalid | 0 | An invalid trigger action, one that is not exposed to the user, occurred. |
Insert | 1 | An INSERT Transact-SQL statement was executed. |
Update | 2 | An UPDATE Transact-SQL statement was executed. |
Delete | 3 | A DELETE Transact-SQL statement was executed. |
CreateTable | 21 | A CREATE TABLE Transact-SQL statement was executed. |
AlterTable | 22 | An ALTER TABLE Transact-SQL statement was executed. |
DropTable | 23 | A DROP TABLE Transact-SQL statement was executed. |
CreateIndex | 24 | A CREATE INDEX Transact-SQL statement was executed. |
AlterIndex | 25 | An ALTER INDEX Transact-SQL statement was executed. |
DropIndex | 26 | A DROP INDEX Transact-SQL statement was executed. |
CreateSecurityExpression | 31 | Not available. |
DropSecurityExpression | 33 | Not available. |
CreateSynonym | 34 | A CREATE SYNONYM Transact-SQL statement was executed. |
DropSynonym | 36 | A DROP SYNONYM Transact-SQL statement was executed. |
CreateView | 41 | A CREATE VIEW Transact-SQL statement was executed. |
AlterView | 42 | An ALTER VIEW Transact-SQL statement was executed. |
DropView | 43 | A DROP VIEW Transact-SQL statement was executed. |
CreateProcedure | 51 | A CREATE PROCEDURE Transact-SQL statement was executed. |
AlterProcedure | 52 | An ALTER PROCEDURE Transact-SQL statement was executed. |
DropProcedure | 53 | A DROP PROCEDURE Transact-SQL statement was executed. |
CreateFunction | 61 | A CREATE FUNCTION Transact-SQL statement was executed. |
AlterFunction | 62 | An ALTER FUNCTION Transact-SQL statement was executed. |
DropFunction | 63 | A DROP FUNCTION Transact-SQL statement was executed. |
CreateTrigger | 71 | A CREATE TRIGGER Transact-SQL statement was executed. |
AlterTrigger | 72 | An ALTER TRIGGER Transact-SQL statement was executed. |
DropTrigger | 73 | A DROP TRIGGER Transact-SQL statement was executed. |
CreateEventNotification | 74 | A CREATE EVENT NOTIFICATION Transact-SQL statement was executed. |
DropEventNotification | 76 | A DROP EVENT NOTIFICATION Transact-SQL statement was executed. |
CreateType | 91 | A CREATE TYPE Transact-SQL statement was executed. |
DropType | 93 | A DROP TYPE Transact-SQL statement was executed. |
CreateAssembly | 101 | A CREATE ASSEMBLY Transact-SQL statement was executed. |
AlterAssembly | 102 | An ALTER ASSEMBLY Transact-SQL statement was executed. |
DropAssembly | 103 | A DROP ASSEMBLY Transact-SQL statement was executed. |
CreateUser | 131 | A CREATE USER Transact-SQL statement was executed. |
AlterUser | 132 | An ALTER USER Transact-SQL statement was executed. |
DropUser | 133 | A DROP USER Transact-SQL statement was executed. |
CreateRole | 134 | A CREATE ROLE Transact-SQL statement was executed. |
AlterRole | 135 | An ALTER ROLE Transact-SQL statement was executed. |
DropRole | 136 | A DROP ROLE Transact-SQL statement was executed. |
CreateAppRole | 137 | A CREATE APPLICATION ROLE Transact-SQL statement was executed. |
AlterAppRole | 138 | An ALTER APPLICATION ROLE Transact-SQL statement was executed. |
DropAppRole | 139 | A DROP APPLICATION ROLE Transact-SQL statement was executed. |
CreateSchema | 141 | A CREATE SCHEMA Transact-SQL statement was executed. |
AlterSchema | 142 | An ALTER SCHEMA Transact-SQL statement was executed. |
DropSchema | 143 | A DROP SCHEMA Transact-SQL statement was executed. |
CreateLogin | 144 | A CREATE LOGIN Transact-SQL statement was executed. |
AlterLogin | 145 | An ALTER LOGIN Transact-SQL statement was executed. |
DropLogin | 146 | A DROP LOGIN Transact-SQL statement was executed. |
CreateMsgType | 151 | A CREATE MESSAGE TYPE Transact-SQL statement was executed. |
DropMsgType | 153 | A DROP MESSAGE TYPE Transact-SQL statement was executed. |
CreateContract | 154 | A CREATE CONTRACT Transact-SQL statement was executed. |
DropContract | 156 | A DROP CONTRACT Transact-SQL statement was executed. |
CreateQueue | 157 | A CREATE QUEUE Transact-SQL statement was executed. |
AlterQueue | 158 | An ALTER QUEUE Transact-SQL statement was executed. |
DropQueue | 159 | A DROP QUEUE Transact-SQL statement was executed. |
CreateService | 161 | A CREATE SERVICE Transact-SQL statement was executed. |
AlterService | 162 | An ALTER SERVICE Transact-SQL statement was executed. |
DropService | 163 | A DROP SERVICE Transact-SQL statement was executed. |
CreateRoute | 164 | A CREATE ROUTE Transact-SQL statement was executed. |
AlterRoute | 165 | An ALTER ROUTE Transact-SQL statement was executed. |
DropRoute | 166 | A DROP ROUTE Transact-SQL statement was executed. |
GrantStatement | 167 | A GRANT Transact-SQL statement was executed. |
DenyStatement | 168 | A DENY Transact-SQL statement was executed. |
RevokeStatement | 169 | A REVOKE Transact-SQL statement was executed. |
GrantObject | 170 | A GRANT OBJECT Transact-SQL statement was executed. |
DenyObject | 171 | A DENY Object Permissions Transact-SQL statement was executed. |
RevokeObject | 172 | A REVOKE OBJECT Transact-SQL statement was executed. |
CreateBinding | 174 | A CREATE_REMOTE_SERVICE_BINDING event type was specified when an event notification was created on the database or server instance. |
AlterBinding | 175 | An ALTER_REMOTE_SERVICE_BINDING event type was specified when an event notification was created on the database or server instance. |
DropBinding | 176 | A DROP_REMOTE_SERVICE_BINDING event type was specified when an event notification was created on the database or server instance. |
CreatePartitionFunction | 191 | A CREATE PARTITION FUNCTION Transact-SQL statement was executed. |
AlterPartitionFunction | 192 | An ALTER PARTITION FUNCTION Transact-SQL statement was executed. |
DropPartitionFunction | 193 | A DROP PARTITION FUNCTION Transact-SQL statement was executed. |
CreatePartitionScheme | 194 | A CREATE PARTITION SCHEME Transact-SQL statement was executed. |
AlterPartitionScheme | 195 | An ALTER PARTITION SCHEME Transact-SQL statement was executed. |
DropPartitionScheme | 196 | A DROP PARTITION SCHEME Transact-SQL statement was executed. |
Remarks
The TriggerAction enumeration is used by the SqlTriggerContext class to indicate what action fired the trigger.
For more information, see the Transact-SQL Reference.