File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes JDBC and the fly likes Am I correct in where clause... Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Databases » JDBC
Bookmark "Am I correct in where clause..." Watch "Am I correct in where clause..." New topic
Author

Am I correct in where clause...

Elahe Shafie
Ranch Hand

Joined: Dec 12, 2001
Posts: 291
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);


Thanks,
Elahe
Elahe Shafie
Ranch Hand

Joined: Dec 12, 2001
Posts: 291
Sorry last line is
PrepStmt.setInt(6,bugNumber);
Mike Curwen
Ranch Hand

Joined: Feb 20, 2001
Posts: 3695

Moving this from Servlets -> JDBC
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Am I correct in where clause...
 
Similar Threads
How to use two query in one servlet
What is wrong with this Update Query!!!!
Please Help(executeQuery)
Please help....confused:
PreparedStatement not throwing error when it should