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 SQLException Closed Resultset Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of OCA/OCP Java SE 7 Programmer I & II Study Guide this week in the OCPJP forum!
JavaRanch » Java Forums » Databases » JDBC
Bookmark "SQLException Closed Resultset" Watch "SQLException Closed Resultset" New topic
Author

SQLException Closed Resultset

kavitha lingam
Greenhorn

Joined: Jul 03, 2003
Posts: 1
Hello
We are getting intermittent SQLException like Closed Resultset. We have Oracle 10g and using ojdbc14.jar. Find below the trace.


java.sql.SQLException: Closed Resultset: next
at
oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:11
2)
at
oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:14
6)
at
oracle.jdbc.driver.OracleResultSetImpl.next(OracleResultSetImpl.java:175
)
at
com.mchange.v2.c3p0.impl.NewProxyResultSet.next(NewProxyResultSet.java:2
859)
at
com.evant.em3.runtime.framework.domain.SqlExecutor.executeQuery(SqlExecu
tor.java:682)
at
com.evant.em3.runtime.framework.domain.SqlExecutor.executeQuery(SqlExecu
tor.java:628)


Some times we get a different trace

java.lang.NullPointerException
at
com.mchange.v2.c3p0.impl.NewProxyStatement.getResultSet(NewProxyStatemen
t.java:430)
at
com.evant.em3.runtime.framework.domain.SqlExecutor.executeQuery(SqlExecu
tor.java:664)
at
com.evant.em3.runtime.framework.domain.SqlExecutor.executeQuery(SqlExecu
tor.java:628)
at
com.evant.em3.runtime.framework.domaintostorage.repository.RelationalPer
sistenceStrategy.executeQuery(RelationalPersistenceStrategy.java:152)
at

Any guidance on fixing this would really help

Thanks
Jeanne Boyarsky
author & internet detective
Marshal

Joined: May 26, 2003
Posts: 30789
    
157

Have you ruled out obvious causes yet such as the connection timing out or not always closing your resources?


[Blog] [JavaRanch FAQ] [How To Ask Questions The Smart Way] [Book Promos]
Blogging on Certs: SCEA Part 1, Part 2 & 3, Core Spring 3, OCAJP, OCPJP beta, TOGAF part 1 and part 2
Paul Clapham
Bartender

Joined: Oct 14, 2005
Posts: 18715
    
    8

Another possibility is connections, or result sets, being accidentally shared between threads.
 
Don't get me started about those stupid light bulbs.
 
subject: SQLException Closed Resultset