Online Documentation for SQL Manager for PostgreSQL
Creating/editing event trigger
Use the Trigger tab of Event Trigger Editor to create/edit an event trigger and specify its definition.
Enter a name for the new event trigger, or modify the name of the event trigger being edited.
Enables/disables the event trigger immediately after it is created or modified.
Select the event on which the event trigger should be fired:
Before DDL command
This option is equal to the ddl_command_start PosgreSQL event. This event occurs just before the execution of a CREATE, ALTER, or DROP command. No check whether the affected object exists or doesn't exist is performed before the event trigger fires.
After SQL drop
This option is equal to the sql_drop PosgreSQL event. This event occurs just before the ddl_command_end event trigger for any operation that drops database objects.
After DDL command
This option is equal to the ddl_command_end PosgreSQL event. This event occurs just after the execution of a CREATE, ALTER, or DROP command.
You can filter the list of commands on which the event trigger should be fired. To select a command, you need to move it from the Available Commands list to the Selected Commands list. Use the buttons or drag-and-drop operations to move the commands from one list to another.
If you want the trigger to be fired on all commands of the event check the Fire on all commands option.
In the lower area define the user-supplied function that is declared as taking no argument and returning type event_trigger. This function is executed when the trigger fires.
You can use already existing function and provide its name in the Function name field or create new one.