Re: Asymmetric partition-wise JOIN - Mailing list pgsql-hackers

From Alexander Pyhalov
Subject Re: Asymmetric partition-wise JOIN
Date
Msg-id feba91824546bf8242a9c420286edc97@postgrespro.ru
Whole thread Raw
In response to Re: Asymmetric partition-wise JOIN  (Andrey Lepikhov <a.lepikhov@postgrespro.ru>)
List pgsql-hackers
Andrey Lepikhov писал 2021-07-06 12:28:
> On 5/7/21 23:15, Zhihong Yu wrote:
>> On Mon, Jul 5, 2021 at 2:57 AM Andrey Lepikhov 
>> <a.lepikhov@postgrespro.ru <mailto:a.lepikhov@postgrespro.ru>> wrote:
>> +            * Can't imagine situation when join relation already 
>> exists. But in
>> +            * the 'partition_join' regression test it happens.
>> +            * It may be an indicator of possible problems.
>> Should a log be added in the above case ?
> I made additional analysis of this branch of code. This situation can
> happen in the case of one child or if we join two plane tables with
> partitioned. Both situations are legal and I think we don't needed to
> add any log message here.
> Other mistakes were fixed.

Hi.

Small  typo in comment in src/backend/optimizer/plan/setrefs.c:

  281
  282     /*
  283      * Adjust RT indexes of AppendRelInfos and add to final 
appendrels list.
  284      * The AppendRelInfos are copied, because as a part of a 
subplan its could
  285      * be visited many times in the case of asymmetric join.
  286      */
  287     foreach(lc, root->append_rel_list)
  288     {

its  -> it (or they) ?
-- 
Best regards,
Alexander Pyhalov,
Postgres Professional



pgsql-hackers by date:

Previous
From: Dean Rasheed
Date:
Subject: Re: [PATCH] expand the units that pg_size_pretty supports on output
Next
From: Peter Eisentraut
Date:
Subject: Re: Fix pkg-config file for static linking