3 .\" Author: The PostgreSQL Global Development Group
4 .\" Generator: DocBook XSL Stylesheets vsnapshot <http://docbook.sf.net/>
6 .\" Manual: PostgreSQL 18.0 Documentation
7 .\" Source: PostgreSQL 18.0
10 .TH "DROP INDEX" "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 .\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
20 .\" -----------------------------------------------------------------
21 .\" * set default formatting
22 .\" -----------------------------------------------------------------
23 .\" disable hyphenation
25 .\" disable justification (adjust text to left margin only)
27 .\" -----------------------------------------------------------------
28 .\" * MAIN CONTENT STARTS HERE *
29 .\" -----------------------------------------------------------------
31 DROP_INDEX \- remove an index
35 DROP INDEX [ CONCURRENTLY ] [ IF EXISTS ] \fIname\fR [, \&.\&.\&.] [ CASCADE | RESTRICT ]
40 drops an existing index from the database system\&. To execute this command you must be the owner of the index\&.
45 Drop the index without locking out concurrent selects, inserts, updates, and deletes on the index\*(Aqs table\&. A normal
49 lock on the table, blocking other accesses until the index drop can be completed\&. With this option, the command instead waits until conflicting transactions have completed\&.
51 There are several caveats to be aware of when using this option\&. Only one index name can be specified, and the
53 option is not supported\&. (Thus, an index that supports a
57 constraint cannot be dropped this way\&.) Also, regular
59 commands can be performed within a transaction block, but
60 \fBDROP INDEX CONCURRENTLY\fR
61 cannot\&. Lastly, indexes on partitioned tables cannot be dropped using this option\&.
65 is always non\-concurrent, as no other session can access them, and non\-concurrent index drop is cheaper\&.
70 Do not throw an error if the index does not exist\&. A notice is issued in this case\&.
75 The name (optionally schema\-qualified) of an index to remove\&.
80 Automatically drop objects that depend on the index, and in turn all objects that depend on those objects (see
86 Refuse to drop the index if any objects depend on it\&. This is the default\&.
90 This command will remove the index
107 language extension\&. There are no provisions for indexes in the SQL standard\&.
109 CREATE INDEX (\fBCREATE_INDEX\fR(7))