de.opitzconsulting.orcas.diff.DatabaseHandlerHsqlDb Maven / Gradle / Ivy
The newest version!
package de.opitzconsulting.orcas.diff;
import java.util.ArrayList;
import java.util.List;
import de.opitzconsulting.orcas.sql.CallableStatementProvider;
import de.opitzconsulting.orcas.sql.WrapperExecutePreparedStatement;
import de.opitzconsulting.origOrcasDsl.CharType;
public class DatabaseHandlerHsqlDb extends DatabaseHandler
{
@Override
public void createOrcasUpdatesTable( String pOrcasUpdatesTableName, CallableStatementProvider pOrcasCallableStatementProvider )
{
String lSql = "create table " + pOrcasUpdatesTableName + " ( scup_id INTEGER IDENTITY PRIMARY KEY, scup_script_name varchar(4000) not null, scup_logname varchar(100) not null, scup_date date not null, scup_schema varchar(30) not null)";
new WrapperExecutePreparedStatement( lSql, pOrcasCallableStatementProvider ).execute();
}
@Override
public void insertIntoOrcasUpdatesTable( String pOrcasUpdatesTableName, CallableStatementProvider pOrcasCallableStatementProvider, String pFilePart, String pLogname )
{
String lSql = "" + //
" insert into " + pOrcasUpdatesTableName + "(" + //
" scup_script_name," + //
" scup_date," + //
" scup_schema," + //
" scup_logname" + //
" )" + //
" values (" + //
" ?," + //
" current_timestamp," + //
" CURRENT_SCHEMA," + //
" ?" + //
" )" + //
"";
List
© 2015 - 2024 Weber Informatics LLC | Privacy Policy