• Post Reply Bookmark Topic Watch Topic
  • New Topic

Large ResultSet

 
Pappu Kumar
Ranch Hand
Posts: 69
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have a query that returns anywhere from 1000 to 5000 rows. I have to show them to one screen (no paging). What are the ways in which i can get the best time performance. Let me know what i can do at Database, Server or whats the best Java technology that would gimme the best performance.
 
Jamie Robertson
Ranch Hand
Posts: 1879
MySQL Database Suse
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Save them in an ArrayList and display them in a JTable or such.
I'd hate to be the guy that has to read all 5000 rows!
 
Loren Rosen
Ranch Hand
Posts: 156
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You may want to experiment with ResultSet.setFetchSize to see what value is the best.
 
What are you doing? You are supposed to be reading this tiny ad!
the new thread boost feature brings a LOT of attention to your favorite threads
https://coderanch.com/t/674455/Thread-Boost-feature
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!