• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Result Set size problem?

 
faisal ishaque
Greenhorn
Posts: 14
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello,
I have a problem to get the exact size of result set. Let us assume that my query get 20 results and another query get 30 results, now how can i adjust the size of my collection (array) dynamically to adjust w.r.t result set size.
I use some technique that first get the count then perform another query for results , but this does not seems to be a good technique because there are some restriction of using ORACLE COUNT METHOD.
Can any one give me the best practices for setting collection(array) size w.r.t the result set size.
thanks and best regards.
Faisal Ishaque
 
Joe Ess
Bartender
Posts: 9340
10
Linux Mac OS X Windows
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Use a data structure that grows dynamically, like java.util.ArrayList.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic