| From: | Adrian Klaver <adrian(dot)klaver(at)aklaver(dot)com> |
|---|---|
| To: | Mark <nvpostgres(at)gmail(dot)com>, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
| Cc: | pgsql-general(at)lists(dot)postgresql(dot)org |
| Subject: | Re: Debugging --- ERROR: function does not exist |
| Date: | 2026-10-25 14:54:21 |
| Message-ID: | 941f31ac-e44c-4f10-87e8-1e0ab19f7206@aklaver.com |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-general |
On 10/25/26 7:42 AM, Adrian Klaver wrote:
> On 10/25/26 6:26 AM, Mark wrote:
>> Thanks for the input Tom
>>
>> 1) SHOW search_path; -- produces the following and the function was in
>> the public schema (and both created by the same user)
>>
>> search_path
>> -----------------
>> "$user", public
>>
>> 2) I was calling it with:
>> SELECTgetSessDbKey (jSessionId, jUser, 'functionName'::text,
>> vSessDbKey, vSessRet, vGetSessDbKeyMess);
>
> This is not the same as:
>
> SELECT getSessDbKey (iSessionId => '1234'::text, iUser => 'cmd
> test'::text, iFunction => 'cmd test'::text);
>
> Note 3 parameters vs 6 in the 2).
>
> And from here:
>
> https://www.postgresql.org/docs/current/plpgsql-
> declarations.html#PLPGSQL-DECLARATION-PARAMETERS
>
> "To call a function with OUT parameters, omit the output parameter(s) in
> the function call: ..."
>
Forgot to add there is INOUT if you want to use the parameters either
way, see:
https://www.postgresql.org/docs/current/sql-createfunction.html
"argmode
The mode of an argument: IN, OUT, INOUT, or VARIADIC. If omitted,
the default is IN. Only OUT arguments can follow a VARIADIC one. Also,
OUT and INOUT arguments cannot be used together with the RETURNS TABLE
notation.
"
--
Adrian Klaver
adrian(dot)klaver(at)aklaver(dot)com
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Mark | 2026-10-25 14:55:44 | Re: Debugging --- ERROR: function does not exist |
| Previous Message | Adrian Klaver | 2026-10-25 14:42:55 | Re: Debugging --- ERROR: function does not exist |