Using Triggers - Teradata Database

Database Introduction

Product
Teradata Database
Release Number
15.00
Language
English (United States)
Last Update
2018-09-25
dita:id
B035-1091
lifecycle
previous
Product Category
Teradata® Database

You can use triggers to do various things:

  • Define a trigger on the subject table to ensure that the UPDATE, INSERT, MERGE, and DELETE statements performed to the subject table are propagated to another table.
  • Use triggers for auditing. For example, you can define a trigger which causes the INSERT statements in a log table when an employee receives a raise higher than 10%.
  • Use a trigger to disallow massive UPDATE, INSERT, MERGE, or DELETE during business hours.
  • Use a trigger to set a threshold. For example, you can use triggers to set thresholds for inventory of each item by store, to create a purchase order when the inventory drops below a threshold, or to change a price if the daily volume does not meet expectations.
  • Use a trigger to call SQL stored procedures and external stored procedures.