postgresqlTriggers and Trigger Functions
The trigger will be associated with the specified table or view and will execute the specified function function_name when certain events occur.
Please use below link for complete overview of:
Basic PL/pgSQL Trigger Function
This modified text is an extract of the original Stack Overflow Documentation created by following contributors
and released under CC BY-SA 3.0