Hi everybody,
I am connecting to an Access 97 database with a servlet through JDBC.
I am trying to update a field in a table.
When i try to update it with the following code
 
         String updateString = "UPDATE dernek " + "SET password ='" + password1+ "' WHERE ebid='" + id + "' ";
         stmt.executeUpdate(updateString);

It gives an sql eror like 'too few parameters. Expected 1' and does not update the table

but when try this
 
       String updateString = "UPDATE dernek " + "SET password ='" + password1+ "' WHERE ebid='" + id + "' ";
         stmt.executeUpdate(updateString);
         stmt.executeUpdate(updateString);

It again gives the same error for the first executeUpdate but updates the table in the second try.
Isn't this strange?
What may be the reason for this?

Thanks in advance

Cem Vardar
Reseach Assistant
METU-IE ___________________________________________________________________________ To unsubscribe, send email to [EMAIL PROTECTED] and include in the body of the message "signoff SERVLET-INTEREST". Archives: http://archives.java.sun.com/archives/servlet-interest.html Resources: http://java.sun.com/products/servlet/external-resources.html LISTSERV Help: http://www.lsoft.com/manuals/user/user.html

Reply via email to