Join Martin Guidry for an in-depth discussion in this video Why use triggers?, part of SQL Server: Triggers Stored Procedures and Functions.
Let's talk little bit about some of the advantages of using triggers.…Triggers can be used to audit changes to the database.…We can set up triggers on tables to record every change to every record in the table.…Typically, this is accomplished by copying the record before it's modified to a different table.…A table we might call historical data.…Triggers can also be used to ensure the integrity of our data.…SQL Server has some other ways to do this such as checks and constraints.…
But those are designed to be pretty simple.…They check for a data type or they might check to make sure some value is…greater than or less than some other value.…Triggers allow for more robust logic.…We can generate data integrity rules that implement complex business logic,…that can reference multiple tables based on the value in those tables, decide if…a certain piece of data is valid or invalid.…Triggers can also be used to block mistakes.…Triggers can undo an attempt to change data.…
They can even undo an attempt to change the structure of the database.…
- Comparing triggers, functions, and stored procedures
- Installing and configuring SQL Server
- Creating a stored procedure
- Returning data using data sets
- Creating user-defined functions
- Using "after," "instead," and nested triggers
- Modifying existing stored procedures
- Implementing logging on DELETE
- Choosing between T-SQL and CLR
- Executing a stored procedure
- Passing parameters
Skill Level Advanced
1. Getting Started
2. Installing SQL Server
Configuring your environment4m 53s
3. Stored Procedures
4. User-Defined Functions
6. Putting It All Together
7. Using CLR Assemblies
8. Exploring an ASP.NET Web Application
Next steps1m 43s
- Mark as unwatched
- Mark all as unwatched
Are you sure you want to mark all the videos in this course as unwatched?
This will not affect your course history, your reports, or your certificates of completion for this course.Cancel
Take notes with your new membership!
Type in the entry box, then click Enter to save your note.
1:30Press on any video thumbnail to jump immediately to the timecode shown.
Notes are saved with you account but can also be exported as plain text, MS Word, PDF, Google Doc, or Evernote.