When I tried to query a database table and created a bean to store each record that matched the criteria ( the resultSet it returned is pretty big), I have this problem. Anybody has any clues of how to fix it?
increase the JVM heap space by passing higher value than default at server start up. Look @ this
SCJP <br />SCWCD <br />SCBCD <br />SCEA-1
Joined: Feb 01, 2008
Thanks for your quick reply. My goal is to compare each record of two tables from two different databases and intially, I got connection to the first table and for each record of the resultSet returned(266,000 records in total), I connected to the 2nd database and compare with all the records of the 2nd table. Then, I got Maximum open cursors exceeded error. So, I changed to try to use an ArrayList of bean to hold all the data from the first table and after I closed the first connection then do the comparison, then I have this heap space problem. If I don't want to change the default value for heap space and go back to my first thought, any idear of how to fix the too many open cursors problem?
Thanks for any advice.
Joined: Jan 22, 2008
Now this really becomes a database question. May be you can ask this in database forum..