SQL SERVER – Types of Triggers

A client of Comprehensive Database Performance Health Check asked me questions about types of triggers. Let us learn about it.

SQL SERVER -  Types of Triggers TypesofTriggers-800x329

Well, there are three main types of triggers.

  1. DDL Trigger – DDL trigger runs when Data Definition Language events occur in the database. DDL events are CREATE, ALTER and DROP statements.
  2. DML Trigger – DML trigger runs when Data Modification Language events occur in the database. DML events are INSERT, UPDATE, and DELETE statements.
  3. Logon Trigger – Logon triggers runs when Logon events happen in SQL Server. When you log in to the SQL Server instance, the triggers execute.

Do you use triggers for your business applications? I have stopped using them for many years and it has been fantastically fine. Let me know your thoughts in the comments.

Here are my few recent videos and I would like to know what is your feedback about them. Do not forget to subscribe SQL in Sixty Seconds series.

Reference: Pinal Dave (http://blog.SQLAuthority.com)

, ,
Previous Post
SQL SERVER – How to Break Mirroring?
Next Post
SQL SERVER – Threads Not Counted for Max Worker Threads

Related Posts

3 Comments. Leave new

  • Thank yoiu

    Reply
  • DML events include INSERT, UPDATE, or DELETE statements…

    Reply
  • If I had the power to decide, I’d avoid triggers as well. But as most departments just buy software and make me implement it, the use of triggers is the choice of the unknown software developers of those products.

    Reply

Leave a Reply

Menu