aboutsummaryrefslogtreecommitdiff
path: root/doc/src/sgml/ref/drop_index.sgml
diff options
context:
space:
mode:
Diffstat (limited to 'doc/src/sgml/ref/drop_index.sgml')
-rw-r--r--doc/src/sgml/ref/drop_index.sgml229
1 files changed, 93 insertions, 136 deletions
diff --git a/doc/src/sgml/ref/drop_index.sgml b/doc/src/sgml/ref/drop_index.sgml
index 149afff0779..b6086ffff39 100644
--- a/doc/src/sgml/ref/drop_index.sgml
+++ b/doc/src/sgml/ref/drop_index.sgml
@@ -1,5 +1,5 @@
<!--
-$Header: /cvsroot/pgsql/doc/src/sgml/ref/drop_index.sgml,v 1.16 2002/07/12 18:43:13 tgl Exp $
+$Header: /cvsroot/pgsql/doc/src/sgml/ref/drop_index.sgml,v 1.17 2003/05/04 02:23:16 petere Exp $
PostgreSQL documentation
-->
@@ -8,161 +8,118 @@ PostgreSQL documentation
<refentrytitle id="SQL-DROPINDEX-TITLE">DROP INDEX</refentrytitle>
<refmiscinfo>SQL - Language Statements</refmiscinfo>
</refmeta>
+
<refnamediv>
- <refname>
- DROP INDEX
- </refname>
- <refpurpose>
- remove an index
- </refpurpose>
+ <refname>DROP INDEX</refname>
+ <refpurpose>remove an index</refpurpose>
</refnamediv>
+
<refsynopsisdiv>
- <refsynopsisdivinfo>
- <date>1999-07-20</date>
- </refsynopsisdivinfo>
- <synopsis>
+<synopsis>
DROP INDEX <replaceable class="PARAMETER">index_name</replaceable> [, ...] [ CASCADE | RESTRICT ]
- </synopsis>
-
- <refsect2 id="R2-SQL-DROPINDEX-1">
- <refsect2info>
- <date>1998-04-15</date>
- </refsect2info>
- <title>
- Inputs
- </title>
- <para>
- <variablelist>
- <varlistentry>
- <term><replaceable class="PARAMETER">index_name</replaceable></term>
- <listitem>
- <para>
- The name (optionally schema-qualified) of an index to remove.
- </para>
- </listitem>
- </varlistentry>
- <varlistentry>
- <term>CASCADE</term>
- <listitem>
- <para>
- Automatically drop objects that depend on the index.
- </para>
- </listitem>
- </varlistentry>
- <varlistentry>
- <term>RESTRICT</term>
- <listitem>
- <para>
- Refuse to drop the index if there are any dependent objects.
- This is the default.
- </para>
- </listitem>
- </varlistentry>
- </variablelist>
- </para>
- </refsect2>
-
- <refsect2 id="R2-SQL-DROPINDEX-2">
- <refsect2info>
- <date>1998-04-15</date>
- </refsect2info>
- <title>
- Outputs
- </title>
- <para>
- <variablelist>
- <varlistentry>
- <term><computeroutput>
-DROP INDEX
- </computeroutput></term>
- <listitem>
- <para>
- The message returned if the command completes successfully.
- </para>
- </listitem>
- </varlistentry>
- <varlistentry>
- <term><computeroutput>
-ERROR: index "<replaceable class="PARAMETER">index_name</replaceable>" does not exist
- </computeroutput></term>
- <listitem>
- <para>
- This message occurs if <replaceable class="PARAMETER">index_name</replaceable>
- is not an index in the database.
- </para>
- </listitem>
- </varlistentry>
- </variablelist>
- </para>
- </refsect2>
+</synopsis>
</refsynopsisdiv>
- <refsect1 id="R1-SQL-DROPINDEX-1">
- <refsect1info>
- <date>1998-04-15</date>
- </refsect1info>
- <title>
- Description
- </title>
+ <refsect1>
+ <title>Description</title>
+
<para>
<command>DROP INDEX</command> drops an existing index from the database
system. To execute this command you must be the owner of
the index.
</para>
+ </refsect1>
+
+ <refsect1>
+ <title>Parameters</title>
- <refsect2 id="R2-SQL-DROPINDEX-3">
- <refsect2info>
- <date>1998-04-15</date>
- </refsect2info>
- <title>
- Notes
- </title>
- <para>
- <command>DROP INDEX</command> is a <productname>PostgreSQL</productname>
- language extension.
- </para>
- <para>
- Refer to
- <xref linkend="sql-createindex" endterm="sql-createindex-title">
- for information on how to create indexes.
- </para>
- </refsect2>
+ <variablelist>
+ <varlistentry>
+ <term><replaceable class="PARAMETER">index_name</replaceable></term>
+ <listitem>
+ <para>
+ The name (optionally schema-qualified) of an index to remove.
+ </para>
+ </listitem>
+ </varlistentry>
+
+ <varlistentry>
+ <term><literal>CASCADE</literal></term>
+ <listitem>
+ <para>
+ Automatically drop objects that depend on the index.
+ </para>
+ </listitem>
+ </varlistentry>
+
+ <varlistentry>
+ <term><literal>RESTRICT</literal></term>
+ <listitem>
+ <para>
+ Refuse to drop the index if any objects depend on it. This is
+ the default.
+ </para>
+ </listitem>
+ </varlistentry>
+ </variablelist>
</refsect1>
- <refsect1 id="R1-SQL-DROPINDEX-2">
- <title>
- Usage
- </title>
+ <refsect1>
+ <title>Diagnostics</title>
+
+ <variablelist>
+ <varlistentry>
+ <term><computeroutput>DROP INDEX</computeroutput></term>
+ <listitem>
+ <para>
+ Message returned if the command completes successfully.
+ </para>
+ </listitem>
+ </varlistentry>
+
+ <varlistentry>
+ <term><computeroutput>ERROR: index "<replaceable class="PARAMETER">index_name</replaceable>" does not exist</computeroutput></term>
+ <listitem>
+ <para>
+ This message is returned if <replaceable
+ class="PARAMETER">index_name</replaceable> is not an existing
+ index.
+ </para>
+ </listitem>
+ </varlistentry>
+ </variablelist>
+ </refsect1>
+
+ <refsect1>
+ <title>Examples</title>
+
<para>
- This command will remove the <literal>title_idx</literal> index:
+ This command will remove the index <literal>title_idx</literal>:
- <programlisting>
- DROP INDEX title_idx;
- </programlisting>
+<programlisting>
+DROP INDEX title_idx;
+</programlisting>
</para>
</refsect1>
- <refsect1 id="R1-SQL-DROPINDEX-3">
- <title>
- Compatibility
- </title>
-
- <refsect2 id="R2-SQL-DROPINDEX-4">
- <refsect2info>
- <date>1998-04-15</date>
- </refsect2info>
- <title>
- SQL92
- </title>
- <para>
- <acronym>SQL92</acronym> defines commands by which to access
- a generic relational database.
- Indexes are an implementation-dependent feature and hence
- there are no index-specific commands or definitions in the
- <acronym>SQL92</acronym> language.
- </para>
- </refsect2>
+ <refsect1>
+ <title>Compatibility</title>
+
+ <para>
+ <command>DROP INDEX</command> is a
+ <productname>PostgreSQL</productname> language extension. There
+ are no provisions for indexes in the SQL standard.
+ </para>
</refsect1>
+
+ <refsect1>
+ <title>See Also</title>
+
+ <simplelist type="inline">
+ <member><xref linkend="sql-createindex" endterm="sql-createindex-title"></member>
+ </simplelist>
+ </refsect1>
+
</refentry>