This week's book giveaway is in the Jobs Discussion forum.
We're giving away four copies of Customer Requirements for Developers and have Marcho Behler on-line!
See this thread for details.
The moose likes JDBC and Relational Databases and the fly likes Can I use prep.execute to update a record? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Customer Requirements for Developers this week in the Jobs Discussion forum!
JavaRanch » Java Forums » Databases » JDBC and Relational Databases
Bookmark "Can I use prep.execute to update a record?" Watch "Can I use prep.execute to update a record?" New topic
Author

Can I use prep.execute to update a record?

Ryan Webb
Greenhorn

Joined: Dec 09, 2009
Posts: 28
Hello ranchers!

I just want to confirm if I can use prep.execute(sql) to update a database record instead of prep.executeUpdate(sql)?

where sql = "UPDATE <table> SET <column> = '<data>'";

Thanks!
Ryan Webb


frustrated to learn c/c++/objective-c
Jan Cumps
Bartender

Joined: Dec 20, 2006
Posts: 2541
    
  10

from the API doc:

Executes the SQL statement in this PreparedStatement object, which may be any kind of SQL statement. .....


OCUP UML fundamental and ITIL foundation
Ryan Webb
Greenhorn

Joined: Dec 09, 2009
Posts: 28
Oh i see! Thanks!

Ryan Webb
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Can I use prep.execute to update a record?
 
It's not a secret anymore!