Re: Oddity in error handling of constraint violation in ExecConstraints for partitioned tables

From: Amit Langote <Langote_Amit_f8(at)lab(dot)ntt(dot)co(dot)jp>
To: Etsuro Fujita <fujita(dot)etsuro(at)lab(dot)ntt(dot)co(dot)jp>, Amit Khandekar <amitdkhan(dot)pg(at)gmail(dot)com>
Cc: pgsql-hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Oddity in error handling of constraint violation in ExecConstraints for partitioned tables
Date: 2017-07-24 10:21:29
Message-ID: 65072100-12d7-9a30-fc3e-6ad32c3e69fc@lab.ntt.co.jp
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On 2017/07/24 17:30, Etsuro Fujita wrote:
> On 2017/07/24 16:16, Amit Khandekar wrote:
>> On 24 July 2017 at 12:11, Amit Langote <Langote_Amit_f8(at)lab(dot)ntt(dot)co(dot)jp>
>> wrote:
>>> Attached is the updated version of your patch.
>
> Good catch, Amit K. and Amit L.!
>
>> Now that this is done, any particular reason it is not done in
>> ExecPartitionCheck() ? I see that there is a do_convert_tuple() in
>> that function, again without changing the slot descriptor.
>
> Yeah, I think we would need that in ExecPartitionCheck() as well.

Yes, we need that there too.

Done that in the attached v3 (including the test where
ExecPartitionCheck() would have crashed without the patch).

Thanks,
Amit

Attachment Content-Type Size
set_slot_descriptor-v3.patch text/plain 6.3 KB

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Rushabh Lathia 2017-07-24 11:36:49 cache lookup failed error for partition key with custom opclass
Previous Message Sokolov Yura 2017-07-24 09:41:08 Re: Increase Vacuum ring buffer.