]> begriffs open source - ai-pg/blob - full-docs/txt/sql-dropoperator.txt
Convert HTML docs to more streamlined TXT
[ai-pg] / full-docs / txt / sql-dropoperator.txt
1
2 DROP OPERATOR
3
4    DROP OPERATOR — remove an operator
5
6 Synopsis
7
8 DROP OPERATOR [ IF EXISTS ] name ( { left_type | NONE } , right_type ) [, ...] [
9  CASCADE | RESTRICT ]
10
11 Description
12
13    DROP OPERATOR drops an existing operator from the database system. To
14    execute this command you must be the owner of the operator.
15
16 Parameters
17
18    IF EXISTS
19           Do not throw an error if the operator does not exist. A notice
20           is issued in this case.
21
22    name
23           The name (optionally schema-qualified) of an existing operator.
24
25    left_type
26           The data type of the operator's left operand; write NONE if the
27           operator has no left operand.
28
29    right_type
30           The data type of the operator's right operand.
31
32    CASCADE
33           Automatically drop objects that depend on the operator (such as
34           views using it), and in turn all objects that depend on those
35           objects (see Section 5.15).
36
37    RESTRICT
38           Refuse to drop the operator if any objects depend on it. This is
39           the default.
40
41 Examples
42
43    Remove the power operator a^b for type integer:
44 DROP OPERATOR ^ (integer, integer);
45
46    Remove the bitwise-complement prefix operator ~b for type bit:
47 DROP OPERATOR ~ (none, bit);
48
49    Remove multiple operators in one command:
50 DROP OPERATOR ~ (none, bit), ^ (integer, integer);
51
52 Compatibility
53
54    There is no DROP OPERATOR statement in the SQL standard.
55
56 See Also
57
58    CREATE OPERATOR, ALTER OPERATOR