AnyLogic
Expand
Font size

@AnyLogicInternalAPI
public class DatabaseStatements
extends Object
This class is internal and shouldn't be called by user.
it may be removed/renamed in future.

Method Summary

Modifier and TypeMethodDescription
static StringgetSQLToSetFieldsInUpdateStatement(String... fields) 
static PreparedStatementprepareInsertStatement(Connection connection, String databaseTableName, boolean returnGeneratedKeys, String... fields) 
static PreparedStatementprepareUpdateStatement(Connection connection, String name, String unicFieldName, String... fields) 
static PreparedStatementprepareUpdateStatementWhereIsNull(Connection connection, String name, String unicFieldName, String... fields) 

Methods inherited from class java.lang.Object

equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

Method Details

prepareInsertStatement

@AnyLogicInternalAPI
public static PreparedStatement prepareInsertStatement(Connection connection,
 String databaseTableName,
 boolean returnGeneratedKeys,
 String... fields)
                                                throws SQLException
Throws:
SQLException

prepareUpdateStatement

@AnyLogicInternalAPI
public static PreparedStatement prepareUpdateStatement(Connection connection,
 String name,
 String unicFieldName,
 String... fields)
                                                throws SQLException
Throws:
SQLException

prepareUpdateStatementWhereIsNull

@AnyLogicInternalAPI
public static PreparedStatement prepareUpdateStatementWhereIsNull(Connection connection,
 String name,
 String unicFieldName,
 String... fields)
                                                           throws SQLException
Throws:
SQLException

getSQLToSetFieldsInUpdateStatement

@AnyLogicInternalAPI
public static String getSQLToSetFieldsInUpdateStatement(String... fields)