Re: [HACKERS] Update comment in ExecPartitionCheck - Mailing list pgsql-hackers

From Etsuro Fujita
Subject Re: [HACKERS] Update comment in ExecPartitionCheck
Date
Msg-id f419c1b0-6380-d2e8-6b81-269b0085add7@lab.ntt.co.jp
Whole thread Raw
In response to Re: [HACKERS] Update comment in ExecPartitionCheck  (Amit Langote <Langote_Amit_f8@lab.ntt.co.jp>)
List pgsql-hackers
On 2017/07/04 18:15, Amit Langote wrote:
> On 2017/07/04 17:55, Etsuro Fujita wrote:
>> This comment in an error handling in ExecPartitionCheck():
>>
>>      if (!ExecCheck(resultRelInfo->ri_PartitionCheckExpr, econtext))
>>      {
>>          char       *val_desc;
>>          Relation    orig_rel = rel;
>>
>>          /* See the comment above. */
>>          if (resultRelInfo->ri_PartitionRoot)
>>
>> should be updated because we don't have any comment on that above in the
>> code.  Since we have a comment on that in ExecConstraints() defined just
>> below that function, I think the comment should be something like this:
>> "See the comment in ExecConstraints().".  Attached is a patch for that.
> 
> Thanks for fixing that.  I forgot to do the same in the patch that got
> committed as 15ce775faa428 [1], which moved that code block from
> ExecConstraints() to ExecPartitionCheck().

Thanks for the explanation!

In relation to this, I found odd behavior in the error handling.  Since 
that is another topic, I'll start a new thread.

Best regards,
Etsuro Fujita




pgsql-hackers by date:

Previous
From: Beena Emerson
Date:
Subject: Re: [HACKERS] increasing the default WAL segment size
Next
From: Etsuro Fujita
Date:
Subject: [HACKERS] Oddity in error handling of constraint violation in ExecConstraintsfor partitioned tables