This week's giveaway is in the Android forum.
We're giving away four copies of Android Security Essentials Live Lessons and have Godfrey Nolan on-line!
See this thread for details.
The moose likes JDBC and the fly likes java sql question Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Databases » JDBC
Bookmark "java sql question" Watch "java sql question" New topic

java sql question

nikil shar
Ranch Hand

Joined: May 25, 2008
Posts: 116
hi all,
was reading through someones java code and i don't really understand the sql which is being constructed below :

i know what the ? is for but what does the '%s' do ??

thanks in advance.
Edwin Dalorzo
Ranch Hand

Joined: Dec 31, 2004
Posts: 961
Perhaps the code you mention was used in a Formatter.

For instance I could write somewhat like this:

Do you know if this is the case?

wood burning stoves
subject: java sql question
Similar Threads
java/MYSQL Serious speed problem.
Java mySql update statement
using more than one sql statements in a preparedstatement
how to get column information for a given sql string