From: | Alexander Korotkov <aekorotkov(at)gmail(dot)com> |
---|---|
To: | Justin Pryzby <pryzby(at)telsasoft(dot)com> |
Cc: | Dmitry Koval <d(dot)koval(at)postgrespro(dot)ru>, Alexander Lakhin <exclusion(at)gmail(dot)com>, pgsql-hackers(at)lists(dot)postgresql(dot)org, Tomas Vondra <tomas(dot)vondra(at)enterprisedb(dot)com>, Alvaro Herrera <alvherre(at)alvh(dot)no-ip(dot)org> |
Subject: | Re: Add SPLIT PARTITION/MERGE PARTITIONS commands |
Date: | 2024-05-08 21:51:32 |
Message-ID: | CAPpHfdvh_XYHahtpoxfzDkvYOFUH1F5tm3JTV=sOZt8M4CTBcA@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On Thu, May 9, 2024 at 12:37 AM Justin Pryzby <pryzby(at)telsasoft(dot)com> wrote:
>
> On Wed, May 08, 2024 at 09:00:10PM +0300, Alexander Korotkov wrote:
> > On Fri, May 3, 2024 at 4:32 PM Alexander Korotkov <aekorotkov(at)gmail(dot)com> wrote:
> > > On Fri, May 3, 2024 at 4:23 PM Justin Pryzby <pryzby(at)telsasoft(dot)com> wrote:
> > > > On Wed, May 01, 2024 at 10:51:24PM +0300, Dmitry Koval wrote:
> > > > > 30.04.2024 23:15, Justin Pryzby пишет:
> > > > > > Is this issue already fixed ?
> > > > > > I wasn't able to reproduce it. Maybe it only happened with earlier
> > > > > > patch versions applied ?
> > > > >
> > > > > I think this was fixed in commit [1].
> > > > >
> > > > > [1] https://github.com/postgres/postgres/commit/fcf80c5d5f0f3787e70fca8fd029d2e08a923f91
> > > >
> > > > I tried to reproduce it at fcf80c5d5f~, but couldn't.
> > > > I don't see how that patch would fix it anyway.
> > > > I'm hoping Alexander can confirm what happened.
> > >
> > > This problem is only relevant for an old version of fix [1], which
> > > overrides schemas for new partitions. That version was never
> > > committed.
> >
> > Here are the patches.
> > 0002 Skips copying extended statistics while creating new partitions in MERGE/SPLIT
> >
> > For 0002 I'd like to hear some feedback on wordings used in docs and comments.
>
> commit message:
>
> Currenlty => Currently
> partiions => partitios
> copying => by copying
Thank you!
>
> > However, parent's table extended statistics already covers all its
> > children.
>
> => That's the wrong explanation. It's not that "stats on the parent
> table cover its children". It's that there are two types of stats:
> stats for the "table hierarchy" and stats for the individual table.
> That's true for single-column stats as well as for extended stats.
> In both cases, that's indicated by the inh flag in the code and in the
> catalog.
>
> The right explanation is that extended stats on partitioned tables are
> not similar to indexes. Indexes on parent table are nothing other than
> a mechanism to create indexes on the child tables. That's not true for
> stats.
>
> See also my prior messages
> ZiJW1g2nbQs9ekwK(at)pryzbyj2023
> Zi5Msg74C61DjJKW(at)pryzbyj2023
Yes, I understand that parents pg_statistic entry with stainherit ==
true includes statistics for the children. I tried to express this by
word "covers". But you're right, this is the wrong explanation.
Can I, please, ask you to revise the patch?
> I think EXCLUDE IDENTITY can/should now also be removed - see 509199587.
> I'm not able to reproduce that problem anyway, even before that...
I will check this.
------
Regards,
Alexander Korotkov
Supabase
From | Date | Subject | |
---|---|---|---|
Next Message | Tom Lane | 2024-05-08 21:52:31 | ALTER EXTENSION SET SCHEMA versus dependent types |
Previous Message | David Rowley | 2024-05-08 21:44:02 | Re: 2024-05-09 release announcement draft |