From: | Robert Haas <robertmhaas(at)gmail(dot)com> |
---|---|
To: | Andrew Gierth <andrew(at)tao11(dot)riddles(dot)org(dot)uk> |
Cc: | Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>, Atri Sharma <atri(dot)jiit(at)gmail(dot)com>, PostgreSQL Hackers <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: WITHIN GROUP patch |
Date: | 2013-10-11 12:31:48 |
Message-ID: | CA+Tgmoa91a2yW3D=+gzN0cGnzF7jo7xNW1ofXZX5ro5=xyQxaw@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On Thu, Oct 10, 2013 at 10:35 PM, Andrew Gierth
<andrew(at)tao11(dot)riddles(dot)org(dot)uk> wrote:
> The first alternative that springs to mind is:
>
> ERROR: Incorrect number of arguments for hypothetical set function
> DETAIL: Number of hypothetical arguments (3) must equal number of ordered columns (2)
I'd suggest trying to collapse that down into a single message; the
DETAIL largely recapitulates the original error message. Also, I'd
suggest identifying the name of the function, since people may not be
able to identify that easily based just on the fact that it's a
hypothetical set function.
Here's one idea, with two variants depending on the direction of the inequality:
ERROR: function "%s" has %d arguments but only %d ordering columns
ERROR: function "%s" has %d ordering columns but only %d arguments
Or else leave out the actual numbers and just state the principle, but
identifying the exact function at fault, e.g.
ERROR: number of arguments to function "%s" does not match number of
ordering columns
--
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company
From | Date | Subject | |
---|---|---|---|
Next Message | Robert Haas | 2013-10-11 12:43:43 | Re: INSERT...ON DUPLICATE KEY LOCK FOR UPDATE |
Previous Message | Huchev | 2013-10-11 11:42:44 | Re: custom hash-based COUNT(DISTINCT) aggregate - unexpectedly high memory consumption |