ddl-partitioning-note-detach-concurrenltly.patch
application/octet-stream
Filename: ddl-partitioning-note-detach-concurrenltly.patch
Type: application/octet-stream
Part: 0
Patch
Format: unified
| File | + | − |
|---|---|---|
| doc/src/sgml/ddl.sgml | 4 | 12 |
| doc/src/sgml/ref/alter_table.sgml | 1 | 1 |
diff --git a/doc/src/sgml/ddl.sgml b/doc/src/sgml/ddl.sgml
index 513112a216..bb494b3f89 100644
--- a/doc/src/sgml/ddl.sgml
+++ b/doc/src/sgml/ddl.sgml
@@ -3926,7 +3926,10 @@ ALTER TABLE measurement DETACH PARTITION measurement_y2006m02;
the data using <command>COPY</command>, <application>pg_dump</application>, or
similar tools. It might also be a useful time to aggregate data
into smaller formats, perform other data manipulations, or run
- reports.
+ reports. Moroever, specifying <literal>CONCURRENTLY</literal> allows
+ the detach operation to finish while taking only
+ <literal>SHARE UPDATE EXCLUSIVE</literal> lock on the parent table; see
+ <xref linkend="sql-altertable-detach-partition"/> for more information.
</para>
<para>
@@ -4163,17 +4166,6 @@ ALTER INDEX measurement_city_id_logdate_key
might be poor.)
</para>
</listitem>
-
- <listitem>
- <para>
- Some operations require a stronger lock when using declarative
- partitioning than when using table inheritance. For example,
- removing a partition from a partitioned table requires taking
- an <literal>ACCESS EXCLUSIVE</literal> lock on the parent table,
- whereas a <literal>SHARE UPDATE EXCLUSIVE</literal> lock is enough
- in the case of regular inheritance.
- </para>
- </listitem>
</itemizedlist>
</para>
diff --git a/doc/src/sgml/ref/alter_table.sgml b/doc/src/sgml/ref/alter_table.sgml
index 6166b26334..3cce2fdbde 100644
--- a/doc/src/sgml/ref/alter_table.sgml
+++ b/doc/src/sgml/ref/alter_table.sgml
@@ -953,7 +953,7 @@ WITH ( MODULUS <replaceable class="parameter">numeric_literal</replaceable>, REM
</listitem>
</varlistentry>
- <varlistentry>
+ <varlistentry id="sql-altertable-detach-partition">
<term><literal>DETACH PARTITION <replaceable class="parameter">partition_name</replaceable> [ CONCURRENTLY | FINALIZE ]</literal></term>
<listitem>