Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.server -> Invalid Cursor (corrected)
Hello,
I had two typos in my post yesterday, so here again:
I am getting the error "invalid cursor" --- I have spent hours on this, I have no clue.
I am calling a procedure from a remote database, which is linked via
a
database link.
The procedure is declared as follows:
CREATE OR REPLACE PACKAGE Pkg_Reports
AS
TYPE refcur IS REF CURSOR;
PROCEDURE GetReport (rep OUT refcur, v_startDate IN DATE);
END Pkg_Reports;
/
PROCEDURE GetReport (rep OUT refcur, v_startDate IN DATE);
IS
BEGIN
OPEN rep FOR SELECT .... ;
END;
/
I am calling the procedure as follows:
CREATE OR REPLACE procedure PROC_TEST
as
c PKG_REPORTS.refcur_at_mylink
v1 varchar2(8); v2 varchar2(20); v3 number;
loop fetch c into v1, v2, v3; -- <-- RUN-TIME ERROR end loop;
Everything is compiling fine. The cursor is open. The variables have
correct types.
But still I am getting a runtime error "Invalid cursor" in the line
marked above. What am I doing wrong?
We are using Oracle 9.2.0.8.
Any help is highly appreciated.
Thank you in advance
Georg Scholz
Received on Wed Nov 14 2007 - 04:11:18 CST
![]() |
![]() |