Re: BUG #2107: Function INOUT parameter not returned to caller, causes plpgsql malfunctions - Mailing list pgsql-bugs

From Tom Lane
Subject Re: BUG #2107: Function INOUT parameter not returned to caller, causes plpgsql malfunctions
Date
Msg-id 2139.1134401571@sss.pgh.pa.us
Whole thread Raw
In response to BUG #2107: Function INOUT parameter not returned to caller, causes plpgsql malfunctions  ("Tony S" <tony@vectorsalad.com>)
Responses Re: BUG #2107: Function INOUT parameter not returned to caller,
List pgsql-bugs
"Tony S" <tony@vectorsalad.com> writes:
> Function defined with INOUT parameter.  Value of parameter is not returned
> to calling function.

You are confused about the meaning and use of INOUT.  It's not some kind
of pass-by-reference parameter, it's just a shorthand for separate IN
and OUT parameters.  In your example, the PERFORM discards the function
result; the original value of 'outparameter' is not and cannot be
modified by the called function.

            regards, tom lane

pgsql-bugs by date:

Previous
From: "Tony"
Date:
Subject: BUG #2108: Function with OUT parameters not recognized, using plpgsql
Next
From: Tom Lane
Date:
Subject: Re: BUG #2108: Function with OUT parameters not recognized, using plpgsql