File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes JDBC and the fly likes memory problem during query Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login
JavaRanch » Java Forums » Java » JDBC
Reply Bookmark "memory problem during query" Watch "memory problem during query" New topic
Author

memory problem during query

Kristof Camelbeke
Ranch Hand

Joined: Nov 28, 2001
Posts: 97
Hello,
I have a question concerning the performance of a database query.
The problem is as follows :
I have a jList with items... When the user selects one, a query is made on the database to do a selection of fields which are then displayed in a jTable (I use an AbstractTableModel to obtain this).
Everything works fine except when I use the application for a while (i.e. selecting
about 10 or more elements from the jList) my memory-usage is boosting up and doesn't go down !
After a while I receive an "out of memory error" and the whole thing stops working..
Is there a way to restore the memory used after a database-query or does this mean that there is
something wrong in my program ??
Here is the code to the event which's starts the query ...
Could anybody give me some help ..
Thanks....
Kristof


[ Edited by Dave to format code ]
[ March 26, 2002: Message edited by: David O'Meara ]
 
 
subject: memory problem during query
 
Threads others viewed
JTable & AbstractTableModel(Delete row problem)
getter not running
How can I debug it ?
Please Help in sorting JTable on multiple column.
how to make JList ListSelectionListener execute only once?
developer file tools