Chapter 29. Creating and Managing Triggers

by Chris Gallelli

IN THIS CHAPTER

  • Benefits and Uses of Triggers

  • Creating Triggers

  • AFTER Triggers

  • inserted and deleted Tables

  • Checking for Column Updates

  • Nested Triggers

  • Recursive Triggers

  • Enforcing Referential Integrity with Triggers

  • INSTEAD OF Triggers

A trigger is a special type of stored procedure that is executed automatically as part of a data modification. A trigger is created on a table and associated with one or more actions linked with a data modification (INSERT, UPDATE, or DELETE). When one of the actions for which the trigger is defined occurs, the trigger fires automatically. The trigger executes within the same transaction space as the data modification statement, so the trigger becomes a part ...

Get Microsoft® SQL Server™ 2000 Unleashed, Second Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.