This week's giveaway is in the Spring forum.
We're giving away four copies of REST with Spring (video course) and have Eugen Paraschiv on-line!
See this thread for details.
The moose likes JDBC and Relational Databases and the fly likes Closed Statement issue Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of REST with Spring (video course) this week in the Spring forum!
JavaRanch » Java Forums » Databases » JDBC and Relational Databases
Bookmark "Closed Statement issue" Watch "Closed Statement issue" New topic

Closed Statement issue

Dan Parsons
Ranch Hand

Joined: May 30, 2007
Posts: 70
I am getting closed exception messages with my below jdbc connection to Oracle 9i from Tomcat 6 container:
java.sql.SQLException: Closed Statement
java.sql.SQLException: Closed Statement: next

Please advise what I can modify to eliminate the exception messages?

Servlet controller handling of list:
Sagar Rohankar
Ranch Hand

Joined: Feb 19, 2008
Posts: 2904

Dan Parsons wrote:Please advise what I can modify to eliminate the exception messages?

You better post the stack trace . Also are you sure about compilation of this code, try is NOT immediately followed by catch block

[LEARNING bLOG] | [Freelance Web Designer] | [and "Rohan" is part of my surname]
Ireneusz Kordal
Ranch Hand

Joined: Jun 21, 2008
Posts: 423
You can use appache commons DBUtils library:


or you can write your own from scratch.
Consider Paul's rocket mass heater.
subject: Closed Statement issue
jQuery in Action, 3rd edition