From: | Zhihong Yu <zyu(at)yugabyte(dot)com> |
---|---|
To: | Nitin Jadhav <nitinjadhavpostgres(at)gmail(dot)com> |
Cc: | Rajkumar Raghuwanshi <rajkumar(dot)raghuwanshi(at)enterprisedb(dot)com>, Amit Langote <amitlangote09(at)gmail(dot)com>, Pg Hackers <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: Multi-Column List Partitioning |
Date: | 2021-10-22 10:50:33 |
Message-ID: | CALNJ-vQmmRrM3AAAXZumovWrOybC_ALDwPHAJ+3K71tBNcGb5Q@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On Fri, Oct 22, 2021 at 2:48 AM Nitin Jadhav <nitinjadhavpostgres(at)gmail(dot)com>
wrote:
> > While testing further I got a crash with partition wise join enabled for
> multi-col list partitions. please find test case & stack-trace below.
>
> Thanks for sharing. I have fixed the issue in the attached patch.
>
> Thanks & Regards,
> Nitin Jadhav
>
>
>>>>>>
>>>>>> Hi,
+isListBoundDuplicated(List *list_bounds, List *new_bound)
+ Const *value1 = castNode(Const, list_nth(elem, i));
+ Const *value2 = castNode(Const, list_nth(new_bound, i));
Should the upper bound for index i take into account the length of
new_bound ?
If the length of new_bound is always the same as that for elem, please add
an assertion.
For transformPartitionListBounds():
+ deparse_expression((Node *) list_nth(partexprs, j),
+
deparse_context_for(RelationGetRelationName(parent),
+
RelationGetRelid(parent)),
Please consider calling RelationGetRelationName(parent)
and RelationGetRelid(parent) (and assigning to local variables) outside the
loop.
+get_list_datum_count(PartitionBoundSpec **boundspecs, int nparts)
get_list_datum_count -> get_list_datums_count
For partition_bounds_equal():
+ if (b1->isnulls)
+ b1_isnull = b1->isnulls[i][j];
+ if (b2->isnulls)
+ b2_isnull = b2->isnulls[i][j];
Should the initialization of b1_isnull and b2_isnull be done inside the
loop (so that they don't inherit value from previous iteration) ?
Cheers
From | Date | Subject | |
---|---|---|---|
Next Message | Amul Sul | 2021-10-22 13:13:52 | Re: prevent immature WAL streaming |
Previous Message | Bharath Rupireddy | 2021-10-22 10:48:04 | Re: logical decoding/replication: new functions pg_ls_logicaldir and pg_ls_replslotdir |