[BUGS] BUG #14463: refcursor cann't used with array or variadic parameter? - Mailing list pgsql-bugs

From digoal@126.com
Subject [BUGS] BUG #14463: refcursor cann't used with array or variadic parameter?
Date
Msg-id 20161213152548.14897.81245@wrigleys.postgresql.org
Whole thread Raw
Responses Re: [BUGS] BUG #14463: refcursor cann't used with array or variadic parameter?
List pgsql-bugs
The following bug has been logged on the website:

Bug reference:      14463
Logged by:          Zhou Digoal
Email address:      digoal@126.com
PostgreSQL version: 9.6.1
Operating system:   CentOS 6.x x64
Description:

postgres=# CREATE FUNCTION myfunc(variadic ref refcursor[]) RETURNS SETOF
refcursor AS $$                                               
begin   
 open ref[1] for select * from pg_class; 
 return next ref[1];       
 open ref[2] for select * from pg_class;
 return next ref[2];  
end;                               
$$ lANGUAGE plpgsql;
ERROR:  42804: variable "$1" must be of type cursor or refcursor
LINE 3:  open ref[1] for select * from pg_class;
              ^
LOCATION:  plpgsql_yyparse, pl_gram.y:2187
Time: 0.854 ms


--
Sent via pgsql-bugs mailing list (pgsql-bugs@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-bugs

pgsql-bugs by date:

Previous
From: Michael Paquier
Date:
Subject: Re: [BUGS] BUG #14462: Segment Fault recovery mode
Next
From: Pavel Stehule
Date:
Subject: Re: [BUGS] BUG #14463: refcursor cann't used with array or variadic parameter?