From: | Michael Paquier <michael(at)paquier(dot)xyz> |
---|---|
To: | Ashutosh Bapat <ashutosh(dot)bapat(at)enterprisedb(dot)com> |
Cc: | Amit Langote <Langote_Amit_f8(at)lab(dot)ntt(dot)co(dot)jp>, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, David Rowley <david(dot)rowley(at)2ndquadrant(dot)com>, amul sul <sulamul(at)gmail(dot)com>, PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>, Robert Haas <robertmhaas(at)gmail(dot)com> |
Subject: | Re: Partitioning with temp tables is broken |
Date: | 2018-06-19 10:52:41 |
Message-ID: | 20180619105241.GA1548@paquier.xyz |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On Tue, Jun 19, 2018 at 02:50:44PM +0530, Ashutosh Bapat wrote:
> +
> + <listitem>
> + <para>
> + Mixing temporary and permanent relations in the same partition tree
> + is not allowed. Hence, if the root partitioned table is permanent,
>
> Do we want to mention "root" explicitly here?
Yes, let's use "partitioned table" here. The docs also say so for
CREATE TABLE ... PARTITION BY.
> In general it looks like we could write the above paragraph as
> "A permanant partitioned table should have all its partitions
> permanant. A temporary partitioned table should have all its
> partitions temporary and should belong to the same session which
> temporary partitioned table belongs to."
I find the suggestion from Amit more elegant, still you are right that
mentioning that all temporary relations need to be from the same session
would be a good addition :)
I was under the impression that this was implied in the precious
phrasing but you guys visibly don't match with my impression. So I
would suggest this paragraph at the end:
"Mixing temporary and permanent relations in the same partition tree is
not allowed. Hence, if the partitioned table is permanent, so must be
its partitions at all levels and likewise if the partitioned table is
temporary. When using temporary relations, all members of the partition
tree have to be from the same session."
> Looks like MergeAttributes() is doing more than just merging attributes. But
> that's not fault of this patch. It's been so for quite some time.
I also find that a bit depressing, but that's not work for v11 at this
stage.
--
Michael
From | Date | Subject | |
---|---|---|---|
Next Message | Ashutosh Bapat | 2018-06-19 10:56:56 | Re: Partitioning with temp tables is broken |
Previous Message | Alexander Korotkov | 2018-06-19 10:40:38 | Re: Postgres 11 release notes |