• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Iterating resultset

 
Prasath Premkumar
Ranch Hand
Posts: 43
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Hi all,

I have a confusion about iterating resultset.



If the above code segment checks for empty resultsets too, then whats the advantage of using,




Can anyone please explain this and what is the best way to do the iterating part?

Thanks in advance.
 
Christophe Verré
Sheriff
Posts: 14691
16
Eclipse IDE Ubuntu VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Calling first() allow you to move the cursor back to the ResultSet. This could be useful if you are using the same ResultSet somewhere else, and you want to reiterate from the start. If you don't, then you don't need to use first().
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic