]> begriffs open source - ai-pg/blob - full-docs/man7/DROP_OPERATOR.7
Convert HTML docs to more streamlined TXT
[ai-pg] / full-docs / man7 / DROP_OPERATOR.7
1 '\" t
2 .\"     Title: DROP OPERATOR
3 .\"    Author: The PostgreSQL Global Development Group
4 .\" Generator: DocBook XSL Stylesheets vsnapshot <http://docbook.sf.net/>
5 .\"      Date: 2025
6 .\"    Manual: PostgreSQL 18.0 Documentation
7 .\"    Source: PostgreSQL 18.0
8 .\"  Language: English
9 .\"
10 .TH "DROP OPERATOR" "7" "2025" "PostgreSQL 18.0" "PostgreSQL 18.0 Documentation"
11 .\" -----------------------------------------------------------------
12 .\" * Define some portability stuff
13 .\" -----------------------------------------------------------------
14 .\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
15 .\" http://bugs.debian.org/507673
16 .\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html
17 .\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
18 .ie \n(.g .ds Aq \(aq
19 .el       .ds Aq '
20 .\" -----------------------------------------------------------------
21 .\" * set default formatting
22 .\" -----------------------------------------------------------------
23 .\" disable hyphenation
24 .nh
25 .\" disable justification (adjust text to left margin only)
26 .ad l
27 .\" -----------------------------------------------------------------
28 .\" * MAIN CONTENT STARTS HERE *
29 .\" -----------------------------------------------------------------
30 .SH "NAME"
31 DROP_OPERATOR \- remove an operator
32 .SH "SYNOPSIS"
33 .sp
34 .nf
35 DROP OPERATOR [ IF EXISTS ] \fIname\fR ( { \fIleft_type\fR | NONE } , \fIright_type\fR ) [, \&.\&.\&.] [ CASCADE | RESTRICT ]
36 .fi
37 .SH "DESCRIPTION"
38 .PP
39 \fBDROP OPERATOR\fR
40 drops an existing operator from the database system\&. To execute this command you must be the owner of the operator\&.
41 .SH "PARAMETERS"
42 .PP
43 IF EXISTS
44 .RS 4
45 Do not throw an error if the operator does not exist\&. A notice is issued in this case\&.
46 .RE
47 .PP
48 \fIname\fR
49 .RS 4
50 The name (optionally schema\-qualified) of an existing operator\&.
51 .RE
52 .PP
53 \fIleft_type\fR
54 .RS 4
55 The data type of the operator\*(Aqs left operand; write
56 NONE
57 if the operator has no left operand\&.
58 .RE
59 .PP
60 \fIright_type\fR
61 .RS 4
62 The data type of the operator\*(Aqs right operand\&.
63 .RE
64 .PP
65 CASCADE
66 .RS 4
67 Automatically drop objects that depend on the operator (such as views using it), and in turn all objects that depend on those objects (see
68 Section\ \&5.15)\&.
69 .RE
70 .PP
71 RESTRICT
72 .RS 4
73 Refuse to drop the operator if any objects depend on it\&. This is the default\&.
74 .RE
75 .SH "EXAMPLES"
76 .PP
77 Remove the power operator
78 a^b
79 for type
80 integer:
81 .sp
82 .if n \{\
83 .RS 4
84 .\}
85 .nf
86 DROP OPERATOR ^ (integer, integer);
87 .fi
88 .if n \{\
89 .RE
90 .\}
91 .PP
92 Remove the bitwise\-complement prefix operator
93 ~b
94 for type
95 bit:
96 .sp
97 .if n \{\
98 .RS 4
99 .\}
100 .nf
101 DROP OPERATOR ~ (none, bit);
102 .fi
103 .if n \{\
104 .RE
105 .\}
106 .PP
107 Remove multiple operators in one command:
108 .sp
109 .if n \{\
110 .RS 4
111 .\}
112 .nf
113 DROP OPERATOR ~ (none, bit), ^ (integer, integer);
114 .fi
115 .if n \{\
116 .RE
117 .\}
118 .SH "COMPATIBILITY"
119 .PP
120 There is no
121 \fBDROP OPERATOR\fR
122 statement in the SQL standard\&.
123 .SH "SEE ALSO"
124 CREATE OPERATOR (\fBCREATE_OPERATOR\fR(7)), ALTER OPERATOR (\fBALTER_OPERATOR\fR(7))