Java: Prepare a statement without a connection

Posted by r3zn1k on Stack Overflow See other posts from Stack Overflow or by r3zn1k
Published on 2010-05-20T12:24:10Z Indexed on 2010/05/20 12:50 UTC
Read the original article Hit count: 140

Filed under:
|

I'm trying to generate some sql files in my java application. The application will not execute any sql statements, just generate a file with sql statements and save it.

I'd like to use the java.sql.PreparedStatement to create my statements so that i don't have to validate every string etc. with my own methods.

Is there a way to use the PreparedStatement without the calling java.sql.Connection.prepareStatement(String) function, because I don't have a java.sql.Connection?

© Stack Overflow or respective owner

Related posts about java

Related posts about sql