Re: doc: mentioned CREATE+ATTACH PARTITION as an alternative to CREATE TABLE..PARTITION OF

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Justin Pryzby <pryzby(at)telsasoft(dot)com>
Cc: Robert Treat <rob(at)xzilla(dot)net>, Robert Haas <robertmhaas(at)gmail(dot)com>, Andrew Dunstan <andrew(at)dunslane(dot)net>, pgsql-hackers(at)lists(dot)postgresql(dot)org, David Rowley <drowley(at)postgresql(dot)org>, Alvaro Herrera <alvherre(at)alvh(dot)no-ip(dot)org>
Subject: Re: doc: mentioned CREATE+ATTACH PARTITION as an alternative to CREATE TABLE..PARTITION OF
Date: 2023-03-16 21:27:30
Message-ID: 3980888.1679002050@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Justin Pryzby <pryzby(at)telsasoft(dot)com> writes:
> On Thu, Mar 16, 2023 at 04:52:07PM -0400, Tom Lane wrote:
> It is possible to use <link linkend="sql-altertable"><command>ALTER
> TABLE ATTACH/DETACH PARTITION</command></link> to perform these
> operations with a weaker lock, thus reducing interference with
> concurrent operations on the partitioned table.

> Note that in order for DETACH+DROP to use a lower lock level, it has to be
> DETACH CONCURRENTLY. ATTACH is implicitly uses a lower lock level, but for
> DETACH it's only on request.

Right, but that's the sort of detail you should read on that command's man
page, we don't need to duplicate it in N other places.

regards, tom lane

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Andres Freund 2023-03-16 21:53:30 Re: More weird compiler warnings
Previous Message Tomas Vondra 2023-03-16 21:20:10 Re: Add LZ4 compression in pg_dump