wood burning stoves 2.0*
The moose likes JDBC and the fly likes Update query is wrong? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of The Java EE 7 Tutorial Volume 1 or Volume 2 this week in the Java EE forum
or jQuery UI in Action in the JavaScript forum!
JavaRanch » Java Forums » Databases » JDBC
Bookmark "Update query is wrong?" Watch "Update query is wrong?" New topic
Author

Update query is wrong?

sahar sa
Ranch Hand

Joined: Jul 06, 2009
Posts: 102
Hi,
Im having problem with this Update query, I dont know what is wrong? I checked with sun but couldnt find any thing different. still got error!
any idea?
here is the code:



and error:


Thank you so much!
Sahar.

Srikkanth Mohanasundaram
Ranch Hand

Joined: Feb 07, 2007
Posts: 185

I guess this is the problem.
Change this to


Thanks,
Srikkanth
sahar sa
Ranch Hand

Joined: Jul 06, 2009
Posts: 102
I find the answer:
the three methods execute, executeQuery, and executeUpdate are modified so that they take no argument:
source:
http://java.sun.com/j2se/1.4.2/docs/guide/jdbc/getstart/preparedstatement.html
thanks,
Sahar.
Satya Maheshwari
Ranch Hand

Joined: Jan 01, 2007
Posts: 368
If that is the case, did your code even compile?


Thanks and Regards
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Update query is wrong?