Win a copy of Design for the Mind this week in the Design forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

get multiple value

 
raya jaya
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hello,
when i execute this code, it just give me one studentID number


how cn i get more than one number of studentID

[Added code tags - see UseCodeTags for details]
 
William P O'Sullivan
Ranch Hand
Posts: 859
Chrome IBM DB2 Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Welcome raya,

Sorry to be honest, It seems you need to do some more basic Java programming.

Your if statement is working fine. The result set has a "next" (or first) record,
you add it to the collection, then leave the if. There could be 10000 more results.

Try reading about loops and in particular the "while" statement.

WP
 
raya jaya
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
thank you
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic