Re: CALL and named parameters

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: "David G(dot) Johnston" <david(dot)g(dot)johnston(at)gmail(dot)com>
Cc: Dominique Devienne <ddevienne(at)gmail(dot)com>, Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>, "pgsql-general(at)lists(dot)postgresql(dot)org" <pgsql-general(at)lists(dot)postgresql(dot)org>
Subject: Re: CALL and named parameters
Date: 2025-08-07 14:21:31
Message-ID: 1566947.1754576491@sss.pgh.pa.us
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-general

"David G. Johnston" <david(dot)g(dot)johnston(at)gmail(dot)com> writes:
> On Thursday, August 7, 2025, Dominique Devienne <ddevienne(at)gmail(dot)com> wrote:
>> What's not nice is in the way it failed IMHO. I guess I persist it's
>> not a user friendly message :)

> Then write the error message you would have liked to see.

The message presumably was like

ERROR: procedure ... does not exist
HINT: No procedure matches the given name and argument types. You might need to add explicit type casts.

That HINT hasn't been updated since we added named arguments, but
"argument names don't match" is now also a possible failure reason.
The simplest possible change would be, say,

HINT: No procedure matches the given name and argument names/types. You might need to add explicit type casts.

Not sure if that's good enough, but the matching rules are
complex enough that it'd be hard to be definitive about
the argument name being the problem.

regards, tom lane

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Dominique Devienne 2025-08-07 14:26:34 Re: CALL and named parameters
Previous Message Dominique Devienne 2025-08-07 14:18:43 Re: CALL and named parameters