Building and Optimizing Triggers in SQL Server

Learn how to design and implement triggers in SQL Server using real-world examples.
Start Course for Free
4 Hours15 Videos49 Exercises7,142 Learners
3800 XP

Create Your Free Account

By continuing, you accept our Terms of Use, our Privacy Policy and that your data is stored in the USA. You confirm you are at least 16 years old (13 if you are an authorized Classrooms user).

Loved by learners at thousands of companies

Course Description

Auditing your SQL Server database and keeping data integrity can be a challenging task for DBAs and database developers. SQL Server triggers are special types of stored procedures designed to help you achieve consistency and integrity of your database. This course will teach you how to work with triggers and use them in real-life examples. Specifically, you will learn about the use cases and limitations of triggers and get practice designing and implementing them. You will also learn to optimize triggers to fit your specific needs.

  1. 1

    Introduction to Triggers

    An introduction to the basic concepts of SQL Server triggers. Create your first trigger using T-SQL code. Learn how triggers are used and what alternatives exist.
    Play Chapter Now
  2. 2

    Classification of Triggers

    Learn about the different types of SQL Server triggers: AFTER triggers (DML), INSTEAD OF triggers (DML), DDL triggers, and logon triggers.
    Play Chapter Now
  3. 3

    Trigger Limitations and Use Cases

    Find out known limitations of triggers, as well as common use cases for AFTER triggers (DML), INSTEAD OF triggers (DML) and DDL triggers.
    Play Chapter Now
  4. 4

    Trigger Optimization and Management

    Learn to delete and modify triggers. Acquaint yourself with the way trigger management is done. Learn how to investigate problematic triggers in practice.
    Play Chapter Now
In the following tracks
Data AnalystData EngineerSQL Server for Database Administrators
Becca RobinsMona KhalilMarianna Lamnina
Florin Angelescu Headshot

Florin Angelescu

Database Developer
I am an experienced database developer with over 7 years of expertise in SQL Server development and administration. I also use PowerShell actively for process and task automation and deployments. In recent years, I have developed a new passion for Azure services for migration and maintenance, diving further into moving on-premise services to cloud, which I truly believe is the future. I'm a proactive, results-oriented team player. I always want to learn new things and seek new challenges that will contribute to my professional development, and also feel accomplished when I can bring new knowledge to other people.
See More

What do other learners have to say?

I've used other sites—Coursera, Udacity, things like that—but DataCamp's been the one that I've stuck with.

Devon Edwards Joseph
Lloyds Banking Group

DataCamp is the top resource I recommend for learning data science.

Louis Maiden
Harvard Business School

DataCamp is by far my favorite website to learn from.

Ronald Bowers
Decision Science Analytics, USAA