Win a copy of Re-engineering Legacy Software this week in the Refactoring forum
or Docker in Action in the Cloud/Virtualization forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Understanding types of Result Sets

 
Shridhar Raghavan
Ranch Hand
Posts: 71
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

I have been looking around at result sets. JAVA ResultSets

I wanted to understand

1 - SENSITIVE Scrollable resultset and an INSENSITIVE one
2 - Cursor Holdability

i.e.
HOLD_CURSORS_OVER_COMMIT: ResultSet cursors are not closed; they are holdable: they are held open when the method commit is called. Holdable cursors might be ideal if your application uses mostly read-only ResultSet objects.
CLOSE_CURSORS_AT_COMMIT: ResultSet objects (cursors) are closed when the commit method is called. Closing cursors when this method is called can result in better performance for some applications.

 
Tim McGuire
Ranch Hand
Posts: 820
IntelliJ IDE Tomcat Server VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Scroll sensitive means that your result set is dynamic. If the underlying data changes while the result set is alive and it is scroll sensitive, then your result set is updated with the most recent information. Exactly how this is done is "implementation defined".

Holdable means you give the application control over what happens to the result set when commit is called.
You may want to keep your result set open. You can see how "CLOSE_ON_COMMIT" would use less resources.



 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic