Alter Trigger, Disable trigger, enable

PostreSQL tutorial – Alter / Disable trigger

Alter postgresql trigger

Syntax

ALTER TRIGGER trigger_name 
ON table_name RENAME TO new_trigger_name;

Example – Alter postgresql trigger

ALTER TRIGGER customers_trigger 
ON customers RENAME TO new_customers_trigger;

Disable postgresql trigger

Syntax

ALTER TABLE table_name 
DISABLE TRIGGER trigger_name;

Example – Disable postgresql trigger

ALTER TABLE customers 
DISABLE TRIGGER customers_trigger;

Enable postgresql trigger

Syntax

ALTER TABLE table_name 
ENABLE TRIGGER trigger_name;

Example – Enable postgresql trigger

ALTER TABLE customers 
ENABLE TRIGGER customers_trigger;

Create trigger |
Drop trigger