From: | David Rowley <david(dot)rowley(at)2ndquadrant(dot)com> |
---|---|
To: | Robert Haas <robertmhaas(at)gmail(dot)com> |
Cc: | Michael Paquier <michael(at)paquier(dot)xyz>, PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org> |
Subject: | Re: Should new partitions inherit their tablespace from their parent? |
Date: | 2018-11-23 04:03:59 |
Message-ID: | CAKJS1f_0nPCG5-Tq5i+UaSiQX4euUJ4h3vD0RsfaSKXE=6kU-Q@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On Fri, 9 Nov 2018 at 06:58, Robert Haas <robertmhaas(at)gmail(dot)com> wrote:
> On Wed, Nov 7, 2018 at 9:43 PM Michael Paquier <michael(at)paquier(dot)xyz> wrote:
> > On Thu, Nov 08, 2018 at 12:50:40PM +1300, David Rowley wrote:
> > > How about we record the tablespace option for the partitioned table in
> > > reltablespace instead of saving it as 0. Newly created partitions
> > > which don't have a TABLESPACE mentioned in the CREATE TABLE command
> > > should be created in their direct parent partitioned tables
> > > tablespace.
> >
> > I have seen enough complains on the mailing lists regarding the way
> > tablespaces are handled for partitioned tables and their partitions that
> > it looks like a very good idea to make the tablespace being inherited
> > automatically, by setting up reltablespace to a non-zero value even if
> > a partitioned table has no physical presence. Of course not on v11 or
> > older releases, just on HEAD. It is no good to have partitioned indexes
> > and partitioned tables being handling inconsistently for such things.
>
> +1.
Here's a patch for that. Parking here until January's commitfest.
--
David Rowley http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Training & Services
Attachment | Content-Type | Size |
---|---|---|
v1-0001-Allow-newly-created-partitions-to-inherit-their-p.patch | application/octet-stream | 8.9 KB |
From | Date | Subject | |
---|---|---|---|
Next Message | Tom Lane | 2018-11-23 04:30:33 | Re: Hitting CheckRelationLockedByMe() ASSERT with force_generic_plan |
Previous Message | Hubert Zhang | 2018-11-23 02:22:27 | Re: Control your disk usage in PG: Introduction to Disk Quota Extension |