Re: error detail when partition not found

From: Amit Langote <Langote_Amit_f8(at)lab(dot)ntt(dot)co(dot)jp>
To: Robert Haas <robertmhaas(at)gmail(dot)com>
Cc: Pg Hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: error detail when partition not found
Date: 2017-02-27 04:24:19
Message-ID: a98d5b7a-ab85-2385-4d8f-3f0c7f015058@lab.ntt.co.jp
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Thanks for the review.

On 2017/02/27 2:39, Robert Haas wrote:
> On Tue, Feb 21, 2017 at 7:28 AM, Amit Langote
> <Langote_Amit_f8(at)lab(dot)ntt(dot)co(dot)jp> wrote:
>> Simon pointed out in a nearby thread [0] that the detail part of
>> partition-not-found error should show just the partition keys. I posted a
>> patch on that thread [1], but to avoid confusion being caused by multitude
>> of patches over there I'm re-posting it here.
>
> Thanks. GetPartitionFailureData seems like a strange name for a
> datatype, particularly the "Get" part. How about
> PartitionRoutingFailureInfo? Or just two out parameters.

Went with two out parameters instead of a new struct.

> Spelling: BuildSlotPartitinKeyDescription (in comment).

Fixed.

> ExecBuildSlotPartitionKeyDescription could have a comment saying that
> it's LIKE BuildIndexValueDescription() instead of copy-and-pasting the
> comments. And maybe BuildIndexValueDescription() could also get a
> comment saying that if we change anything there, we should check
> whether ExecBuildSlotPartitionKeyDescription() needs a similar change.

OK, I modified the comments. Although, I kept comments that are a bit
different.

Updated patch is attached.

Thanks,
Amit

Attachment Content-Type Size
0001-Show-only-the-partition-key-upon-failing-to-find-a-p.patch text/x-diff 18.1 KB

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Kyotaro HORIGUCHI 2017-02-27 04:33:05 Re: IF (NOT) EXISTS in psql-completion
Previous Message Amit Kapila 2017-02-27 03:03:33 Re: Enabling parallelism for queries coming from SQL or other PL functions