if(statementMustBeClosedByMe)KongaDbUtils.close(statement);
}
}
private void doWriteRecord(CROM table, String sql, List<CROM> params) throws SQLException {
PreparedStatementCache statementCache = getStatementCacheForTable(table);
PreparedStatement statement ;
boolean statementMustBeClosedByMe=true;
if (sqlBuilder.hasColumnNonBind()) {
statement = statementCache.createNewStatement(sql);
} else {
storeSqlForErrorReporting(sql, params);
statement = statementCache.getPreparedStatement(sql);
statementMustBeClosedByMe = statementCache.mustLastReturnedStatementBeClosedByCaller();
}
try {
int index=1;
for(CROM param: params){
String value=param.getValue();