PowerDesigner trigger templates and template items allow you to create triggers in a modular reusable fashion.
PowerDesigner uses pre-defined trigger templates to create triggers to implement referential integrity between tables, and you can also create your own. Trigger templates exist for each type of trigger supported by the DBMS, each identifying:
-
A time relevant to an event (either before or after)
-
An event that can occur to a table row (either Delete, Insert, or Update)
-
The code that performs the trigger action, and which may contain references to trigger template items, which are re-usable blocks of script.
You can create trigger templates and trigger template items in your DBMS definition file (see Viewing and Editing the DBMS Definition File) or in your model.