Re: [HACKERS] dubious error message from partition.c

2017-08-10 Thread Amit Langote
(Sorry Robert for the duplicate message, I mistakenly didn't hit Reply All) On Fri, Aug 11, 2017 at 2:54 Robert Haas wrote: > On Wed, Aug 9, 2017 at 10:14 PM, Amit Langote > wrote: > >> That seems like overkill. I'm good with "greater than

Re: [HACKERS] dubious error message from partition.c

2017-08-10 Thread Robert Haas
On Wed, Aug 9, 2017 at 10:14 PM, Amit Langote wrote: >> That seems like overkill. I'm good with "greater than or equal to". > > Attached updated patch has "greater than or equal to". Committed, with one small change which I hope will be considered an improvement.

Re: [HACKERS] dubious error message from partition.c

2017-08-09 Thread Amit Langote
On 2017/08/10 5:59, Tom Lane wrote: > Alvaro Herrera writes: >> Dean Rasheed wrote: >>> There was an earlier suggestion to use "greater than or equal to". I >>> think that would work quite well: > >> Is it possible to detect the equality case specifically and use a >>

Re: [HACKERS] dubious error message from partition.c

2017-08-09 Thread Tom Lane
Alvaro Herrera writes: > Dean Rasheed wrote: >> There was an earlier suggestion to use "greater than or equal to". I >> think that would work quite well: > Is it possible to detect the equality case specifically and use a > different errdetail? Something like "the

Re: [HACKERS] dubious error message from partition.c

2017-08-09 Thread Alvaro Herrera
Dean Rasheed wrote: > On 9 August 2017 at 13:03, Robert Haas wrote: > > On Tue, Aug 8, 2017 at 11:34 PM, Tom Lane wrote: > >> A small suggestion is that it'd be better to write it like "Specified > >> upper bound \"%s\" precedes lower bound \"%s\"." I

Re: [HACKERS] dubious error message from partition.c

2017-08-09 Thread Dean Rasheed
On 9 August 2017 at 13:03, Robert Haas wrote: > On Tue, Aug 8, 2017 at 11:34 PM, Tom Lane wrote: >> A small suggestion is that it'd be better to write it like "Specified >> upper bound \"%s\" precedes lower bound \"%s\"." I think "succeeds" has >> more

Re: [HACKERS] dubious error message from partition.c

2017-08-09 Thread Robert Haas
On Tue, Aug 8, 2017 at 11:34 PM, Tom Lane wrote: > A small suggestion is that it'd be better to write it like "Specified > upper bound \"%s\" precedes lower bound \"%s\"." I think "succeeds" has > more alternate meanings than "precedes", so the wording you have seems > more

Re: [HACKERS] dubious error message from partition.c

2017-08-08 Thread Amit Langote
On 2017/08/09 13:03, David G. Johnston wrote: > On Tue, Aug 8, 2017 at 8:34 PM, Tom Lane wrote: > >> A small suggestion is that it'd be better to write it like "Specified >> upper bound \"%s\" precedes lower bound \"%s\"." I think "succeeds" has >> more alternate meanings

Re: [HACKERS] dubious error message from partition.c

2017-08-08 Thread David G. Johnston
On Tue, Aug 8, 2017 at 8:34 PM, Tom Lane wrote: > A small suggestion is that it'd be better to write it like "Specified > upper bound \"%s\" precedes lower bound \"%s\"." I think "succeeds" has > more alternate meanings than "precedes", so the wording you have seems > more

Re: [HACKERS] dubious error message from partition.c

2017-08-08 Thread Tom Lane
Amit Langote writes: > On 2017/08/09 3:50, Robert Haas wrote: >> In retrospect, I'm not thrilled by this error message, for two reasons: >> 1. It gives no details, as other nearby messages do. For example, >> further down in the function, we have a message

Re: [HACKERS] dubious error message from partition.c

2017-08-08 Thread Amit Langote
On 2017/08/09 3:50, Robert Haas wrote: > In the original table partitioning commit > (f0e44751d7175fa3394da2c8f85e3ceb3cdbfe630), we introduced the > following code, which hasn't changed materially since then: > > +if (partition_rbound_cmp(key, lower->datums, > lower->content,

[HACKERS] dubious error message from partition.c

2017-08-08 Thread Robert Haas
In the original table partitioning commit (f0e44751d7175fa3394da2c8f85e3ceb3cdbfe630), we introduced the following code, which hasn't changed materially since then: +if (partition_rbound_cmp(key, lower->datums, lower->content, true, + upper)