From: | Christoph Moench-Tegeder <cmt(at)burggraben(dot)net> |
---|---|
To: | Dominique Devienne <ddevienne(at)gmail(dot)com> |
Cc: | Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>, pgsql-general(at)lists(dot)postgresql(dot)org |
Subject: | Re: CALL and named parameters |
Date: | 2025-08-07 23:14:07 |
Message-ID: | aJUzP5pwyObo6AeN@elch.exwg.net |
Views: | Whole Thread | Raw Message | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
## Dominique Devienne (ddevienne(at)gmail(dot)com):
> dd_v185=> call "Epos-DBA".db_grant_connect_to(grantee_role => 'dd_joe');
> ERROR: procedure Epos-DBA.db_grant_connect_to(grantee_role =>
> unknown) does not exist
> LINE 1: call "Epos-DBA".db_grant_connect_to(grantee_role => 'dd_joe'...
There's the problem: "unknown" type - consider that string there as
"too flexible", it can be coerced into too many types, so the error
says "unknown".
Consider this demonstration:
db=# call proc1(val => 1);
CALL
db=# call proc1(val => '2');
CALL
db=# call proc1(value => 3);
ERROR: procedure proc1(value => integer) does not exist
LINE 1: call proc1(value => 3);
^
HINT: No procedure matches the given name and argument types. You might need to add explicit type casts.
db=# call proc1(value => '4');
ERROR: procedure proc1(value => unknown) does not exist
LINE 1: call proc1(value => '4');
^
HINT: No procedure matches the given name and argument types. You might need to add explicit type casts.
db=# call proc1(value => text '5');
ERROR: procedure proc1(value => text) does not exist
LINE 1: call proc1(value => text '5');
^
HINT: No procedure matches the given name and argument types. You might need to add explicit type casts.
Regards,
Christoph
--
Spare Space
From | Date | Subject | |
---|---|---|---|
Next Message | Tom Lane | 2025-08-07 23:33:25 | Re: CALL and named parameters |
Previous Message | Adrian Klaver | 2025-08-07 16:03:58 | Re: Libpq.dll |