Milan Oparnica wrote:
Then I've tried:
CREATE FUNCTION foo(insklid int, out sklid int, out elid INT) RETURNS SETOF
record AS $$
BEGIN
RETURN QUERY SELECT sklid,elid FROM skladkol;
RETURN;
END;
$$ LANGUAGE plpgsql;
but it returns 5498 rows (which is exact number of rows in that table) bu
>
> Then I've tried:
>
> CREATE FUNCTION foo(insklid int, out sklid int, out elid INT) RETURNS SETOF
> record AS $$
> BEGIN
>RETURN QUERY SELECT sklid,elid FROM skladkol;
>RETURN;
> END;
> $$ LANGUAGE plpgsql;
know bug :( - your variable names are in collision with column names.
You have t
Alvaro Herrera wrote:
Milan Oparnica escribió:
I've searched documentation (8.3) and didn't find a way to use OUT
variables in same manner as SETOF (RETURN NEXT doesn't create a record
type result).
Can you please give an example of how to return select fld1, fld2 from
table through OUT
Milan Oparnica escribió:
> I've searched documentation (8.3) and didn't find a way to use OUT
> variables in same manner as SETOF (RETURN NEXT doesn't create a record
> type result).
>
> Can you please give an example of how to return select fld1, fld2 from
> table through OUT variables so t
Alvaro Herrera wrote:
Milan Oparnica escribió:
Tom Lane wrote:
Milan Oparnica <[EMAIL PROTECTED]> writes:
Is there any way to use INNER, LEFT and RIGHT JOIN between functions
returning refcursor type.
No. Make them return setof whatever instead.
I would like yo avoid creating custom compo
Milan Oparnica escribió:
> Tom Lane wrote:
>> Milan Oparnica <[EMAIL PROTECTED]> writes:
>>> Is there any way to use INNER, LEFT and RIGHT JOIN between functions
>>> returning refcursor type.
>>
>> No. Make them return setof whatever instead.
>>
> I would like yo avoid creating custom composite
Tom Lane wrote:
Milan Oparnica <[EMAIL PROTECTED]> writes:
Is there any way to use INNER, LEFT and RIGHT JOIN between functions
returning refcursor type.
No. Make them return setof whatever instead.
regards, tom lane
I would like yo avoid creating custom composite t
Milan Oparnica <[EMAIL PROTECTED]> writes:
> Is there any way to use INNER, LEFT and RIGHT JOIN between functions
> returning refcursor type.
No. Make them return setof whatever instead.
regards, tom lane
--
Sent via pgsql-sql mailing list (pgsql-sql@postgresql.org)
To
Hi,
Is there any way to use INNER, LEFT and RIGHT JOIN between functions
returning refcursor type.
Explain:
function1 as refcursor
function2 as refcursor
both functions return columns a and b.
can i join the results of these functions in such manner (or any other):
function3 as refcursor