Clarify documentation that primary key and unique constraints are copied
authorBruce Momjian
Sun, 26 Aug 2012 20:33:11 +0000 (16:33 -0400)
committerBruce Momjian
Sun, 26 Aug 2012 20:33:11 +0000 (16:33 -0400)
for CREATE TABLE LIKE ... INCLUDING INDEXES.

Per report from [email protected]

doc/src/sgml/ref/create_table.sgml

index 19e6f8ed6100e60eebf33243977f0488fc2d3aa1..445ca40695084489cdd90413a31c17ec28068ef5 100644 (file)
@@ -336,16 +336,13 @@ CREATE [ [ GLOBAL | LOCAL ] { TEMPORARY | TEMP } | UNLOGGED ] TABLE [ IF NOT EXI
      
      
       Not-null constraints are always copied to the new table.
-      CHECK constraints will only be copied if
-      INCLUDING CONSTRAINTS is specified; other types of
-      constraints will never be copied. Also, no distinction is made between
-      column constraints and table constraints — when constraints are
-      requested, all check constraints are copied.
-     
-     
-      Any indexes on the original table will not be created on the new
-      table, unless the INCLUDING INDEXES clause is
-      specified.
+      CHECK constraints will be copied only if
+      INCLUDING CONSTRAINTS is specified. 
+      Indexes, PRIMARY KEY, and UNIQUE constraints
+      on the original table will be created on the new table only if the
+      INCLUDING INDEXES clause is specified.
+      No distinction is made between column constraints and table
+      constraints.
      
      STORAGE settings for the copied column definitions will only
       be copied if INCLUDING STORAGE is specified.  The