This week's book giveaway is in the Agile and other Processes forum. We're giving away four copies of The Mikado Method and have Ola Ellnestam and Daniel Brolund on-line! See this thread for details.
Hi- I have a question re: resultsets...if a resultset obj goes out of scope, does it automatically close the rs? or is there a chance it could be left open? We're suing IBM DB2 JDBC 2.0 drivers... thanks, Max Tomlinson
sandeep balyan
Ranch Hand
Joined: Jul 25, 2001
Posts: 134
posted
0
It is always a good practise to close the result set as it can cause a exception some where in application.like null pointer exception .if u close statements than its okee as it does close resultset .. try to do statement close in finally block to keep fair that even if u r program throws exception u r connection and statement is closed .. that means resources r free regds
"balyan", The Java Ranch has thousands of visitors every week, many with surprisingly similar names. To avoid confusion we have a naming convention, described at http://www.javaranch.com/name.jsp. We require names to have at least two words, separated by a space, and strongly recommend that you use your full real name. Please edit your profile and select a new name which meets the requirements. Also, please try not to use contractions (u, r etc) since they often make it harder to understand posts. Thanks. Dave
I agree. Here's the link: http://ej-technologies/jprofiler - if it wasn't for jprofiler, we would need to
run our stuff on 16 servers instead of 3.