PostgreSQL supports table and view triggers. Use the table or view trigger editor to define a trigger.
To define a PostgreSQL trigger
An instance of Trigger is created.
The PostgreSQL Trigger Editor opens.
Note: Click New on the toolbar to create a trigger. Use the Enter filter text box to filter a very large list of triggers to quickly locate the one that you want to define.
Specifies the name of the view or table trigger. Change the name of the trigger in this field.
Specifies when the trigger function should be called.
Generates SQL during forward engineering. Clear the check box if you do not want to generate SQL.
Indicates that the trigger is a row trigger.
Indicates that the trigger is a constraint trigger. The timing of trigger firing can be adjusted by setting constraints.
Indicates whether the constraint can be deferred.
Specifies the default time to check the constraint in case of a deferrable constraint. It is checked only at the end of the transaction.
Specifies the function that is declared as taking no arguments and returning type trigger, which is executed when the trigger fires. Select a function from the drop-down list or click New to create one.
Specifies the type of even on which the trigger will be fired.
Specifies the condition on which the trigger should execute.
Specifies a list of columns. It indicates that the trigger will only fire if at least one of the listed columns is mentioned as a target of the UPDATE command.
The trigger is defined and the PostgreSQL Trigger Editor closes.
For more information on trigger properties, refer to PostgreSQL documentation.
Copyright © 2017 erwin Inc.
All rights reserved.
|
|