Prefer PreparedStatement

PreparedStatement is usually preferred over Statement for these reasons :

In general, it seems safest to use a Statement only when the SQL is of fixed, known form, with no parameters.

See Also :
Keep SQL out of code
Would you use this technique?
Yes   No   Undecided   
© 2009 Hirondelle Systems | Source Code | Contact | License | Quotes | RSS
Individual classes can be used under this BSD License - Last updated on June 28, 2009.
Over 115,000 unique IPs last month - Built with WEB4J.
- In Memoriam : Bill Dirani -