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

2023-03-16 Thread Tom Lane
Justin Pryzby writes: > On Thu, Mar 16, 2023 at 04:52:07PM -0400, Tom Lane wrote: > It is possible to use ALTER > TABLE ATTACH/DETACH PARTITION to perform these > operations with a weaker lock, thus reducing interference with > concurrent operations on the partitioned

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

2023-03-16 Thread Justin Pryzby
On Thu, Mar 16, 2023 at 04:52:07PM -0400, Tom Lane wrote: > Justin Pryzby writes: > > On Thu, Jan 19, 2023 at 04:47:59PM -0500, Robert Treat wrote: > >> I think all of that feedback is useful, I guess the immediate question > >> becomes if Justin wants to try to proceed with his patch

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

2023-03-16 Thread Tom Lane
Justin Pryzby writes: > On Thu, Jan 19, 2023 at 04:47:59PM -0500, Robert Treat wrote: >> I think all of that feedback is useful, I guess the immediate question >> becomes if Justin wants to try to proceed with his patch implementing >> the change, or if adjusting the documentation for the current

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

2023-03-14 Thread Jakub Wartak
Hi, I've tested the attached patch by Justin and it applied almost cleanly to the master, but there was a tiny typo and make postgres-A4.pdf didn't want to run: Note that creating a partition using PARTITION OF => (note lack of closing literal) => Note that creating a partition using PARTITION OF

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

2023-01-19 Thread Justin Pryzby
On Thu, Jan 19, 2023 at 04:47:59PM -0500, Robert Treat wrote: > I think all of that feedback is useful, I guess the immediate question > becomes if Justin wants to try to proceed with his patch implementing > the change, or if adjusting the documentation for the current > implementation is the

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

2023-01-19 Thread Robert Treat
On Wed, Jan 11, 2023 at 4:13 PM Robert Haas wrote: > On Wed, Jan 11, 2023 at 10:48 AM Robert Treat wrote: > > > @Robert: I wonder why shouldn't CREATE..PARTITION OF *also* be patched > > > to first create a table, and then attach the partition, transparently > > > doing what everyone would want,

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

2023-01-11 Thread Robert Haas
On Wed, Jan 11, 2023 at 10:48 AM Robert Treat wrote: > > @Robert: I wonder why shouldn't CREATE..PARTITION OF *also* be patched > > to first create a table, and then attach the partition, transparently > > doing what everyone would want, without having to re-read the updated > > docs or know to

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

2023-01-11 Thread Robert Treat
On Mon, Sep 5, 2022 at 2:04 PM Justin Pryzby wrote: > > On Thu, Aug 04, 2022 at 01:45:49AM -0400, Robert Treat wrote: > > After reading this again, it isn't clear to me that this advice would > > be more appropriately placed into Section 5.11, aka > >

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

2022-09-05 Thread Justin Pryzby
On Thu, Aug 04, 2022 at 01:45:49AM -0400, Robert Treat wrote: > After reading this again, it isn't clear to me that this advice would > be more appropriately placed into Section 5.11, aka > https://www.postgresql.org/docs/current/ddl-partitioning.html, but in > lieu of a specific suggestion for

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

2022-08-03 Thread Robert Treat
On Mon, Jul 18, 2022 at 10:39 AM Andrew Dunstan wrote: > On 2022-07-18 Mo 10:33, Justin Pryzby wrote: > > It's easy to use CREATE TABLE..LIKE + ALTER..ATTACH PARTITION to avoid > > acquiring a strong lock when creating a new partition. > > But it's also easy to forget. > > > > commit

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

2022-07-18 Thread Andrew Dunstan
On 2022-07-18 Mo 10:33, Justin Pryzby wrote: > It's easy to use CREATE TABLE..LIKE + ALTER..ATTACH PARTITION to avoid > acquiring a strong lock when creating a new partition. > But it's also easy to forget. > > commit 76c0d1198cf2908423b321cd3340d296cb668c8e > Author: Justin Pryzby > Date:

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

2022-07-18 Thread Justin Pryzby
It's easy to use CREATE TABLE..LIKE + ALTER..ATTACH PARTITION to avoid acquiring a strong lock when creating a new partition. But it's also easy to forget. commit 76c0d1198cf2908423b321cd3340d296cb668c8e Author: Justin Pryzby Date: Mon Jul 18 09:24:55 2022 -0500 doc: mention CREATE+ATTACH