• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

rs.get???

 
Sarada Bhasker
Ranch Hand
Posts: 94
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Friends,
When I do a rs.getxxx(x) ,am I going back to the database server and fetching the row from the database cache or am I getting the resultset copied to my in my program's memory?
 
prabhat kumar
Ranch Hand
Posts: 114
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
it gets copied in to ur program memory
 
Premkumar N
Greenhorn
Posts: 22
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Saradha:
The ResultSet object fetches based on the row-fetch-size you've specified. and stores it in your program-space .. but once you exhaust this resultset repeatedly-using rs.next() .. it again goes back to the database and fetches again.

setFetchSize(int rows)
JDBC 2.0 Gives the JDBC driver a hint as to the number of rows that should befetched from the database when more rows are needed for this result set.
Prem
 
I agree. Here's the link: http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic