Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.misc -> stored proc problem
Hi,
I am trying to get a stored proc to return a ref cursor. Here's the code I have at the moment:
create or replace package types
as
type cursorType is ref cursor;
end;
/
create or replace procedure retcurs_proc
(mycurs out types.cursorType)
is
begin
open mycurs for select * from emp;
end retcurs_proc;
/
This compiles with no errors. When I do exec retcurs_proc(), I get this error:
PLS-00306: wrong number or types of arguments in call to 'RETCURS_PROC'
Why do I get the error? The procedure has no IN variables so how is there a wrong number of parameters in the above call?
thanks,