]> git.ipfire.org Git - thirdparty/postgresql.git/commitdiff
In CREATE FOREIGN TABLE syntax synopsis, fix partitioning stuff.
authorRobert Haas <rhaas@postgresql.org>
Thu, 26 May 2022 16:55:06 +0000 (12:55 -0400)
committerRobert Haas <rhaas@postgresql.org>
Thu, 26 May 2022 16:55:06 +0000 (12:55 -0400)
Foreign tables can be partitioned, but previous documentation commits
left the syntax synopsis both incomplete and incorrect.

Justin Pryzby and Amit Langote

Discussion: http://postgr.es/m/20220521130922.GX19626@telsasoft.com

doc/src/sgml/ref/create_foreign_table.sgml

index 8e9caabfe71dee42d5d8544becc2c9e9fa727219..69bbee044a8dfc360ac1fa74f6571551cb24943d 100644 (file)
@@ -35,7 +35,8 @@ CREATE FOREIGN TABLE [ IF NOT EXISTS ] <replaceable class="PARAMETER">table_name
   { <replaceable class="PARAMETER">column_name</replaceable> [ WITH OPTIONS ] [ <replaceable class="PARAMETER">column_constraint</replaceable> [ ... ] ]
     | <replaceable>table_constraint</replaceable> }
     [, ... ]
-) ] <replaceable class="PARAMETER">partition_bound_spec</replaceable>
+) ]
+  FOR VALUES <replaceable class="parameter">partition_bound_spec</replaceable>
   SERVER <replaceable class="parameter">server_name</replaceable>
 [ OPTIONS ( <replaceable class="PARAMETER">option</replaceable> '<replaceable class="PARAMETER">value</replaceable>' [, ... ] ) ]
 
@@ -51,6 +52,12 @@ CREATE FOREIGN TABLE [ IF NOT EXISTS ] <replaceable class="PARAMETER">table_name
 
 [ CONSTRAINT <replaceable class="PARAMETER">constraint_name</replaceable> ]
 CHECK ( <replaceable class="PARAMETER">expression</replaceable> ) [ NO INHERIT ]
+
+<phrase>and <replaceable class="PARAMETER">partition_bound_spec</replaceable> is:</phrase>
+
+IN ( { <replaceable class="PARAMETER">numeric_literal</replaceable> | <replaceable class="PARAMETER">string_literal</replaceable> | TRUE | FALSE | NULL } [, ...] ) |
+FROM ( { <replaceable class="PARAMETER">numeric_literal</replaceable> | <replaceable class="PARAMETER">string_literal</replaceable> | TRUE | FALSE | MINVALUE | MAXVALUE } [, ...] )
+  TO ( { <replaceable class="PARAMETER">numeric_literal</replaceable> | <replaceable class="PARAMETER">string_literal</replaceable> | TRUE | FALSE | MINVALUE | MAXVALUE } [, ...] )
 </synopsis>
  </refsynopsisdiv>