This week's book giveaway is in the Design forum.
We're giving away four copies of Design for the Mind and have Victor S. Yocco on-line!
See this thread for details.
Win a copy of Design for the Mind this week in the Design forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

resultset doubt

 
Janardan Kelkar
Ranch Hand
Posts: 72
Eclipse IDE Firefox Browser Suse
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator


the above code gives me an error as shown:
"Invalid cursor state"

what is the default data type of results of an aggregate functions?!
 
Jan Cumps
Bartender
Posts: 2586
11
C++ Linux Netbeans IDE
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
you should call .... rs.next() ....
 
Janardan Kelkar
Ranch Hand
Posts: 72
Eclipse IDE Firefox Browser Suse
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
thank you....how could i do that!!
 
Jeanne Boyarsky
author & internet detective
Marshal
Posts: 34178
340
Eclipse IDE Java VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by Janardan Kelkar:
thank you....how could i do that!!




Note that normally you would have rs.next() is a while loop. count() is a special function that is guaranteed to always return one row (and one column) even if no rows match.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic