1DROP ROUTINE(7) PostgreSQL 11.3 Documentation DROP ROUTINE(7)
2
3
4
6 DROP_ROUTINE - remove a routine
7
9 DROP ROUTINE [ IF EXISTS ] name [ ( [ [ argmode ] [ argname ] argtype [, ...] ] ) ] [, ...]
10 [ CASCADE | RESTRICT ]
11
13 DROP ROUTINE removes the definition of an existing routine, which can
14 be an aggregate function, a normal function, or a procedure. See under
15 DROP AGGREGATE (DROP_AGGREGATE(7)), DROP FUNCTION (DROP_FUNCTION(7)),
16 and DROP PROCEDURE (DROP_PROCEDURE(7)) for the description of the
17 parameters, more examples, and further details.
18
20 To drop the routine foo for type integer:
21
22 DROP ROUTINE foo(integer);
23
24 This command will work independent of whether foo is an aggregate,
25 function, or procedure.
26
28 This command conforms to the SQL standard, with these PostgreSQL
29 extensions:
30
31 · The standard only allows one routine to be dropped per command.
32
33 · The IF EXISTS option
34
35 · The ability to specify argument modes and names
36
37 · Aggregate functions are an extension.
38
39
41 DROP AGGREGATE (DROP_AGGREGATE(7)), DROP FUNCTION (DROP_FUNCTION(7)),
42 DROP PROCEDURE (DROP_PROCEDURE(7)), ALTER ROUTINE (ALTER_ROUTINE(7))
43
44 Note that there is no CREATE ROUTINE command.
45
46
47
48PostgreSQL 11.3 2019 DROP ROUTINE(7)