From: | stark <stark(at)enterprisedb(dot)com> |
---|---|
To: | pgsql-patches <pgsql-patches(at)postgresql(dot)org> |
Subject: | Doc patch for create index |
Date: | 2007-04-03 18:30:50 |
Message-ID: | 87odm5l38l.fsf@oxford.xeocode.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-patches |
A doc patch to add an example of what an invalid index looks like in psql, as
requested by a commenter and Bruce.
Index: doc/src/sgml/ref/create_index.sgml
===================================================================
RCS file: /home/stark/src/REPOSITORY/pgsql/doc/src/sgml/ref/create_index.sgml,v
retrieving revision 1.60
diff -c -r1.60 create_index.sgml
*** doc/src/sgml/ref/create_index.sgml 31 Jan 2007 23:26:03 -0000 1.60
--- doc/src/sgml/ref/create_index.sgml 3 Apr 2007 17:19:25 -0000
***************
*** 332,338 ****
uniqueness violation in a unique index, the <command>CREATE INDEX</>
command will fail but leave behind an <quote>invalid</> index. This index
will be ignored for querying purposes because it might be incomplete;
! however it will still consume update overhead. The recommended recovery
method in such cases is to drop the index and try again to perform
<command>CREATE INDEX CONCURRENTLY</>. (Another possibility is to rebuild
the index with <command>REINDEX</>. However, since <command>REINDEX</>
--- 332,352 ----
uniqueness violation in a unique index, the <command>CREATE INDEX</>
command will fail but leave behind an <quote>invalid</> index. This index
will be ignored for querying purposes because it might be incomplete;
! however it will still consume update overhead. The <application>psql</>
! <command>\d</> command will mark such an <quote>invalid</> index as such:
!
! <programlisting>
! postgres=# \d tab
! Table "public.tab"
! Column | Type | Modifiers
! --------+---------+-----------
! col | integer |
! Indexes:
! "idx" btree (col) INVALID
! </programlisting>
!
! The recommended recovery
method in such cases is to drop the index and try again to perform
<command>CREATE INDEX CONCURRENTLY</>. (Another possibility is to rebuild
the index with <command>REINDEX</>. However, since <command>REINDEX</>
--
Gregory Stark
EnterpriseDB http://www.enterprisedb.com
From | Date | Subject | |
---|---|---|---|
Next Message | FAST PostgreSQL | 2007-04-03 18:33:14 | COPY-able sql log outputs |
Previous Message | Heikki Linnakangas | 2007-04-03 18:03:58 | Re: Fix CheckpointStartLock starvation |