posted 18 years ago
Hi Praveen,
A cursor can be used as an out parameter in a procedure.If you want that cursor to be handled in Java then use CallableStatement.
ArrayList cursor1 = new ArrayList();
CallableStatement cst = connection.prepareCall("{call YourProc(?,?)}");
cst.setString(1,in_param);
cst.registerOutParameter(2,oracle.jdbc.driver.OracleTypes.CURSOR);
cst.execute();
cursor1 =(ResultSet)cst.getObject(2);
Where YourProc as one in param and one out param which is a cursor and store that cursor in an arraylist to use the data available in it
Regards,
Sujith