How to set a bind variable in Java?

From: jacob nikom <jacob_nikom_at_ieee.org>
Date: 19 Feb 2002 16:59:19 -0800
Message-ID: <6eebd424.0202191659.c309ffd_at_posting.google.com>



Hi,

I have a problem with stored function in PL/SQL returning refcursor to Java in Oracle9 on Solaris. When I run the Java program which calls the stored function it complains: "java.sql.SQLException: ORA-01006: bind variable does not exist"

My stored function runs very well in PL/SQL, but when I call it I have to set up a bind variable:

VARIABLE rc REFCURSOR
EXECUTE :rc := rs_sp_getmodrecs_accounts1('jacob',TO_DATE('12-FEB-02','DD-MON-YY'),TO_DATE('14-FEB-02','DD-MON-YY')) print rc

I think the reason for the complain is that I did not set up the bind variable rc in Java. I don't know how to do it. Do you know how to solve this problem?

Thank you,

Jacob Nikom Received on Wed Feb 20 2002 - 01:59:19 CET

Original text of this message