From: | Amit Langote <Langote_Amit_f8(at)lab(dot)ntt(dot)co(dot)jp> |
---|---|
To: | Michael Paquier <michael(dot)paquier(at)gmail(dot)com>, Bruce Momjian <bruce(at)momjian(dot)us> |
Cc: | Pg Hackers <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: Partitioned tables and relfilenode |
Date: | 2017-02-28 04:08:34 |
Message-ID: | b82e3cba-3085-658a-02ad-5a1838235499@lab.ntt.co.jp |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On 2017/02/28 12:29, Michael Paquier wrote:
> On Tue, Feb 28, 2017 at 12:23 PM, Bruce Momjian <bruce(at)momjian(dot)us> wrote:
>> I am a little confused by the above. Is a partitioned table the parent
>> or the children? Reading the code it seems it is the parent, which
>> explains why it works. Can I clarify that?
>
> As I understand things, a partitioned table is a parent relation that
> exists only to link to its child portions, holding as well the
> definitions linking to each partition.
Yes. As I mentioned in my previous email, data inserted into the
partitioned table is routed to its partitions. A partition may be itself
a partitioned table, so the routing continues until we find a leaf
partition. All the partitioned tables in this chain leading to the leaf
partition are RELKIND_PARTITIONED_TABLE ('P') relations and only the leaf
tables are RELKIND_RELATION tables.
Thanks,
Amit
From | Date | Subject | |
---|---|---|---|
Next Message | Jim Nasby | 2017-02-28 04:15:32 | Re: increasing the default WAL segment size |
Previous Message | Tom Lane | 2017-02-28 03:57:24 | Re: PATCH: two slab-like memory allocators |