aboutsummaryrefslogtreecommitdiff
path: root/doc/src
diff options
context:
space:
mode:
authorAlexander Korotkov <akorotkov@postgresql.org>2024-04-30 11:54:56 +0300
committerAlexander Korotkov <akorotkov@postgresql.org>2024-04-30 11:54:56 +0300
commit842c9b27057e8ecea02b816e3ec6c208779b3d39 (patch)
treeccbaf962c9dd7493081d365f8efe12e12c4d17aa /doc/src
parent885742b9f88b9386368ee94df8c94d154677ffba (diff)
downloadpostgresql-842c9b27057e8ecea02b816e3ec6c208779b3d39.tar.gz
postgresql-842c9b27057e8ecea02b816e3ec6c208779b3d39.zip
Document the way partition MERGE/SPLIT operations create new partitions
Reported-by: Justin Pryzby Discussion: https://postgr.es/m/ZilrByTp-pbz6Mvf%40pryzbyj2023 Reviewed-by: Justin Pryzby
Diffstat (limited to 'doc/src')
-rw-r--r--doc/src/sgml/ref/alter_table.sgml12
1 files changed, 12 insertions, 0 deletions
diff --git a/doc/src/sgml/ref/alter_table.sgml b/doc/src/sgml/ref/alter_table.sgml
index fe36ff82e52..fc2dfffe49f 100644
--- a/doc/src/sgml/ref/alter_table.sgml
+++ b/doc/src/sgml/ref/alter_table.sgml
@@ -1153,6 +1153,12 @@ WITH ( MODULUS <replaceable class="parameter">numeric_literal</replaceable>, REM
splitting we have a partition with the same name).
Only simple, non-partitioned partition can be split.
</para>
+ <para>
+ The new partitions will be created the same as tables created with the
+ SQL command <literal>CREATE TABLE <replaceable class="parameter">partition_nameN</replaceable> (LIKE <replaceable class="parameter">name</replaceable> INCLUDING ALL EXCLUDING INDEXES EXCLUDING IDENTITY)</literal>.
+ The indexes and identity are created later, after moving the data
+ into the new partitions.
+ </para>
<note>
<para>
This command acquires an <literal>ACCESS EXCLUSIVE</literal> lock.
@@ -1213,6 +1219,12 @@ WITH ( MODULUS <replaceable class="parameter">numeric_literal</replaceable>, REM
can have the same name as one of the merged partitions. Only simple,
non-partitioned partitions can be merged.
</para>
+ <para>
+ The new partition will be created the same as a table created with the
+ SQL command <literal>CREATE TABLE <replaceable class="parameter">partition_name</replaceable> (LIKE <replaceable class="parameter">name</replaceable> INCLUDING ALL EXCLUDING INDEXES EXCLUDING IDENTITY)</literal>.
+ The indexes and identity are created later, after moving the data
+ into the new partition.
+ </para>
<note>
<para>
This command acquires an <literal>ACCESS EXCLUSIVE</literal> lock.