Interface Database

    • Method Detail

      • ensureSupported

        void ensureSupported()
        Ensure MigrateDB supports this version of this database.
      • getVersion

        Version getVersion()
        Returns:
        The 'major.minor' version of this database.
      • getDefaultDelimiter

        Delimiter getDefaultDelimiter()
      • getCatalog

        String getCatalog()
        Returns:
        The name of the database, by default as determined by JDBC.
      • getCurrentUser

        String getCurrentUser()
      • supportsDdlTransactions

        boolean supportsDdlTransactions()
      • supportsChangingCurrentSchema

        boolean supportsChangingCurrentSchema()
      • getBooleanTrue

        String getBooleanTrue()
        Returns:
        The representation of the value true in a boolean column.
      • getBooleanFalse

        String getBooleanFalse()
        Returns:
        The representation of the value false in a boolean column.
      • quote

        String quote​(String... identifiers)
        Quotes these identifiers for use in SQL queries. Multiple identifiers will be quoted and separated by a dot.
      • catalogIsSchema

        boolean catalogIsSchema()
        Returns:
        true if this database uses a catalog to represent a schema, or false if a schema is simply a schema.
      • usesSingleSession

        boolean usesSingleSession()
        Returns:
        Whether a single session is used for both schema history table management and applying migrations.
      • getMainSession

        Session getMainSession()
        Returns:
        The main session used to manipulate the schema history.
      • getMigrationSession

        Session getMigrationSession()
        Returns:
        The migration session used to apply migrations.
      • getCreateScript

        SqlScript getCreateScript​(SqlScriptFactory sqlScriptFactory,
                                  Table table,
                                  boolean baseline)
        Retrieves the script used to create the schema history table.
        Parameters:
        sqlScriptFactory - The factory used to create the SQL script.
        table - The table to create.
        baseline - Whether to include the creation of a baseline marker.
      • getRawCreateScript

        String getRawCreateScript​(Table table,
                                  boolean baseline)
      • getInsertStatement

        String getInsertStatement​(Table table)
      • getBaselineStatement

        String getBaselineStatement​(Table table)
      • getSelectStatement

        String getSelectStatement​(Table table)
      • getInstalledBy

        String getInstalledBy()
      • supportsEmptyMigrationDescription

        boolean supportsEmptyMigrationDescription()
      • supportsMultiStatementTransactions

        boolean supportsMultiStatementTransactions()
      • getAllSchemas

        List<? extends Schema> getAllSchemas()