Re: UniqueKey on Partitioned table. - Mailing list pgsql-hackers

From Andy Fan
Subject Re: UniqueKey on Partitioned table.
Date
Msg-id CAKU4AWqCxvKT7JUk2evSpnPQZ8KDbqbx7QxxKjx3-zKHCE=aew@mail.gmail.com
Whole thread Raw
In response to Re: UniqueKey on Partitioned table.  (Dmitry Dolgov <9erthalion6@gmail.com>)
Responses Re: UniqueKey on Partitioned table.
List pgsql-hackers


On Sat, Mar 27, 2021 at 3:07 AM Dmitry Dolgov <9erthalion6@gmail.com> wrote:
> On Sat, Feb 20, 2021 at 10:25:59AM +0800, Andy Fan wrote:
>
> The attached is a UnqiueKey with EquivalenceClass patch, I just complete the
> single relation part and may have bugs. I just attached it here for design
> review only. and the not-null-attrs is just v1 which we can continue
> discussing on the original thread[2].

Thanks for the patch. After a short look through it I'm a bit confused
and wanted to clarify, now uniquekeys list could contain both Expr and
EquivalenceClass?

Yes,  That's because I don't want to create a new EquivalenceClass (which
would make the PlannerInfo->eq_classes longer) if we don't have
one , then I just used one Expr instead for this case.  However during the
test, I found some EquivalenceClass with only 1 EquivalenceMember
unexpectedly. 

--
Best Regards

pgsql-hackers by date:

Previous
From: Andrey Borodin
Date:
Subject: Re: MultiXact\SLRU buffers configuration
Next
From: Andy Fan
Date:
Subject: Re: Extend more usecase for planning time partition pruning and init partition pruning.