File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes JDBC and the fly likes java.sql.SQLException: Cursor is closed Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of EJB 3 in Action this week in the EJB and other Java EE Technologies forum!
JavaRanch » Java Forums » Databases » JDBC
Bookmark "java.sql.SQLException: Cursor is closed" Watch "java.sql.SQLException: Cursor is closed" New topic
Author

java.sql.SQLException: Cursor is closed

Kaustubh Dasgupta
Greenhorn

Joined: Jan 22, 2007
Posts: 3
I am returning a ref cursor from my oracle procedure and trying to get the data in my DAO class. But I am getting the following error:

[2/1/07 18:38:41:766 IST] 0000003d SystemErr R java.sql.SQLException: Cursor is closed.

at oracle.jdbc.driver.T4CResultSetAccessor.getCursor(T4CResultSetAccessor.java:323)

at oracle.jdbc.driver.ResultSetAccessor.getObject(ResultSetAccessor.java:85)

at oracle.jdbc.driver.OracleCallableStatement.getObject(OracleCallableStatement.java:1401)

at com.ibm.ws.rsadapter.jdbc.WSJdbcCallableStatement.getObject(WSJdbcCallableStatement.java:443)

at com.harcourt.elearning.services.reporting.persistence.dao.classsummaryreport.ClassSummaryReportDAO.generateReport

Can any one help.

Thanks in advance.

Kaustubh
Srikanth Basa
Ranch Hand

Joined: Jun 06, 2005
Posts: 241
Its hard to conclude the reason without looking at the source.

Check thislink
Muhammad Saifuddin
Ranch Hand

Joined: Dec 06, 2005
Posts: 1321

where you are closing the cursor remove that line. might be it works


Saifuddin..
[Blog][Linkedin] How To Ask Questions On JavaRanch My OpenSource
 
 
subject: java.sql.SQLException: Cursor is closed
 
Similar Threads
ResultSet object is always read only with sprinta2000
Maximum cursor exceed
java.sql.SQLException: Closed Connection: next
SQLException Cursor Closed
Use a ResultSet twice