From: | Amit Langote <amitlangote09(at)gmail(dot)com> |
---|---|
To: | Ashutosh Bapat <ashutosh(dot)bapat(at)enterprisedb(dot)com> |
Cc: | Justin Pryzby <pryzby(at)telsasoft(dot)com>, Alvaro Herrera <alvherre(at)2ndquadrant(dot)com>, Amit Langote <Langote_Amit_f8(at)lab(dot)ntt(dot)co(dot)jp>, David Rowley <david(dot)rowley(at)2ndquadrant(dot)com>, Peter Eisentraut <peter(dot)eisentraut(at)2ndquadrant(dot)com>, PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>, "Shinoda, Noriyoshi (PN Japan FSIP)" <noriyoshi(dot)shinoda(at)hpe(dot)com>, Tomas Vondra <tomas(dot)vondra(at)enterprisedb(dot)com> |
Subject: | Re: doc phrase: "inheritance child" |
Date: | 2022-05-27 03:47:18 |
Message-ID: | CA+HiwqF1LiUffYXXRVWF222Vb25NcW-Ps1U2xn4yj5rMRWNsWQ@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Hi,
On Wed, May 25, 2022 at 1:30 PM Ashutosh Bapat
<ashutosh(dot)bapat(at)enterprisedb(dot)com> wrote:
> @@ -7306,7 +7306,7 @@ SCRAM-SHA-256$<replaceable><iteration count></replaceable>:<replaceable>&l
> <para>
> Normally there is one entry, with <structfield>stainherit</structfield> =
> <literal>false</literal>, for each table column that has been analyzed.
> - If the table has inheritance children, a second entry with
> + If the table has inheritance children or partitions, a second entry with
> <structfield>stainherit</structfield> = <literal>true</literal> is also created. This row
> represents the column's statistics over the inheritance tree, i.e.,
> statistics for the data you'd see with
>
> For partitioned tables only the second entry makes sense. IIRC, we had done some work to remove the first entry. Can you please check whether a partitioned table also has two entries?
Don't think we've made any changes yet that get rid of the parent
partitioned table's entry in pg_statistic:
create table foo (a int) partition by list (a);
create table foo1 partition of foo for values in (1);
analyze foo;
select starelid::regclass, stainherit from pg_statistic where
starelid::regclass in (select relid from pg_partition_tree('foo'));
starelid | stainherit
----------+------------
foo | t
foo1 | f
(2 rows)
Maybe you're thinking of RangeTblEntry that the planner makes 2 copies
for inheritance parents, but only 1 for partition parents as of
e8d5dd6be79.
--
Thanks, Amit Langote
EDB: http://www.enterprisedb.com
From | Date | Subject | |
---|---|---|---|
Next Message | Michael Paquier | 2022-05-27 03:53:11 | Re: Bump MIN_WINNT to 0x0600 (Vista) as minimal runtime in 16~ |
Previous Message | Tom Lane | 2022-05-27 03:01:44 | Re: Assert name/short_desc to prevent SHOW ALL segfault |