This week's book giveaway is in the HTML Pages with CSS and JavaScript forum.
We're giving away four copies of Testing JavaScript Applications and have Lucas da Costa on-line!
See this thread for details.
Win a copy of Testing JavaScript Applications this week in the HTML Pages with CSS and JavaScript forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Bear Bibeault
  • Ron McLeod
  • Jeanne Boyarsky
  • Paul Clapham
Sheriffs:
  • Tim Cooke
  • Liutauras Vilda
  • Junilu Lacar
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • fred rosenberger
  • salvin francis
Bartenders:
  • Piet Souris
  • Frits Walraven
  • Carey Brown

java.sql.SQLException: Exhausted Resultset

 
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

When I try to stress test my servlet with lots of request (clicks), I get the java.sql.SQLException: Exhausted Resultset exception. Anyways to solve this problem?
 
Ranch Hand
Posts: 67
1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Jinal,

I tried a search on Exhausted Resultset exception and got some hits. Did any of these apply to you?
 
Jinal Jhaveri
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
No not yet
 
Ranch Hand
Posts: 1211
Mac IntelliJ IDE
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Post some code, mate, and if there is a logical error in it, somebody may be able to spot it.
 
Ranch Hand
Posts: 1087
Oracle Spring Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Jinal,

How may records are resultset is containing.
what is record count ???
 
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
Jinal , i was getting same error few days back.
What you maybe doing here is opening too much resultsets without closing them.Sometimes its not immediately visible, since u maybe doing it somewhere
recursively.
So try to close result sets as soon as possible.


Monu G
 
Jinal Jhaveri
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks everybody. I just found my own post and thought would post the solution. The problem was because my application was not multithreaded. I had some global variables. After making them local, everything worked fine!
 
Ranch Hand
Posts: 74
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Use : next() method of Resultset.
Reason : resultset.next() Returns Advances the record cursor by one record. Returns a boolean value indicating success or failure. Failure occurs if the cursor moved ...


I was solving the same problem and resolved it through this.

-----------------------------------------------
Pankaj Patel.
SCJP 1.5
Enjoy the world of Programming...
-----------------------------------------------
 
Consider Paul's rocket mass heater.
    Bookmark Topic Watch Topic
  • New Topic