Win a copy of Think Java: How to Think Like a Computer Scientist this week in the Java in General forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Am I correct in where clause...

 
Elahe Shafie
Ranch Hand
Posts: 291
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi all,
Is it the right way in where clause and PrepStmt(last line)
Thanks,
ELahe
PrepStmt =con.prepareStatement("update bug set values (?,?,?,?,?) where bugNumber=?");
PrepStmt.setInt(1,ID);
PrepStmt.setString(2,bdesc);
PrepStmt.setString(3,fixedDate);
PrepStmt.setInt(4,userID);
PrepStmt.setString(5,contact);
PrepStmt.setString(6,bugNumber);
 
Elahe Shafie
Ranch Hand
Posts: 291
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Sorry last line is
PrepStmt.setInt(6,bugNumber);
 
Mike Curwen
Ranch Hand
Posts: 3695
IntelliJ IDE Java Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Moving this from Servlets -> JDBC
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic