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, what are the jdbc objects we must close after finishing a process? db - mysql web server - apache + tomcat in a servlet i use a connection broker from javaexchange and in the service method get a connection and towards the end free the connection. I close the statement and the prepared statements. Should i also close the result set. My application is repeatedly throwing a servlet exception and therefore stops. Can u please help. Regards, dj
prabhat kumar
Ranch Hand
Joined: Apr 11, 2001
Posts: 114
posted
0
ya u shuld also close the resultsets if any.
jlrober
Greenhorn
Joined: Jun 25, 2001
Posts: 10
posted
0
Actually, if you close the Statement only, it will automatically call ResultSet.close() on any resultsets using the statement closed. So you don't "HAVE" to close the resultset explicitly, but it may just be good habit.
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.