1DROP TRIGGER(7)          PostgreSQL 11.3 Documentation         DROP TRIGGER(7)
2
3
4

NAME

6       DROP_TRIGGER - remove a trigger
7

SYNOPSIS

9       DROP TRIGGER [ IF EXISTS ] name ON table_name [ CASCADE | RESTRICT ]
10

DESCRIPTION

12       DROP TRIGGER removes an existing trigger definition. To execute this
13       command, the current user must be the owner of the table for which the
14       trigger is defined.
15

PARAMETERS

17       IF EXISTS
18           Do not throw an error if the trigger does not exist. A notice is
19           issued in this case.
20
21       name
22           The name of the trigger to remove.
23
24       table_name
25           The name (optionally schema-qualified) of the table for which the
26           trigger is defined.
27
28       CASCADE
29           Automatically drop objects that depend on the trigger, and in turn
30           all objects that depend on those objects (see Section 5.13).
31
32       RESTRICT
33           Refuse to drop the trigger if any objects depend on it. This is the
34           default.
35

EXAMPLES

37       Destroy the trigger if_dist_exists on the table films:
38
39           DROP TRIGGER if_dist_exists ON films;
40

COMPATIBILITY

42       The DROP TRIGGER statement in PostgreSQL is incompatible with the SQL
43       standard. In the SQL standard, trigger names are not local to tables,
44       so the command is simply DROP TRIGGER name.
45

SEE ALSO

47       CREATE TRIGGER (CREATE_TRIGGER(7))
48
49
50
51PostgreSQL 11.3                      2019                      DROP TRIGGER(7)
Impressum