Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.misc -> How to set a bind variable in Java?
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 Tue Feb 19 2002 - 18:59:19 CST