Help - Search - Members - Calendar
Full Version: Calling a remote procedure using a dblink and ref cursor.
Oracle DBA Forums > Oracle > Oracle Forum
SickOfOracle
We are trying to call a remote procedure (A) through a dblink (cool.gif in a procedure © and return data using a ref cursor. Attached is the procedure, link and remote procedure. We get ora-02055, 02068, 03113, 06512.

(A)
CREATE OR REPLACE PROCEDURE "CDB"."EST_TEST" (o_cursor in out
types.v_cursor)
as
begin
execute immediate
'begin
open :0 for
select sysdate from dual;
end;' using o_cursor;
end;

(cool.gif
CREATE DATABASE LINK "ACES_CDBDEV" CONNECT TO "ACES"
IDENTIFIED BY "********"
USING 'CDBDEV

©
CREATE OR REPLACE PROCEDURE "ACES"."TEST_PROC" as
v_cursor types.v_cursor;
begin
open v_cursor;
cdb.est_test@aces_cdbdev(v_cursor);

end;

Is there a way to return a result set through a ref_cursor by calling a remore procedure?

Thanks in advance
JJ

Sorry the Smiley icon is the result of (cool.gif and the copyright icon is ©.

JJ
andrew kerber
I dont know the exact cause of the problem, but you might try putting the stored procedure on the other side of the link, ie call the sp through the link.
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here.
Invision Power Board © 2001-2014 Invision Power Services, Inc.