public class OracleDatabase extends AbstractJdbcDatabase
| Modifier and Type | Field and Description |
|---|---|
protected int |
LONG_IDENTIFIERS_LEGNTH |
static int |
ORACLE_12C_MAJOR_VERSION |
static String |
PRODUCT_NAME |
protected int |
SHORT_IDENTIFIERS_LENGTH |
caseSensitive, currentDateTimeFunction, dateFunctions, defaultAutoIncrementBy, defaultAutoIncrementStartWith, defaultCatalogName, defaultSchemaName, quotingStrategy, sequenceCurrentValueFunction, sequenceNextValueFunction, unmodifiableDataTypes, unquotedObjectsAreUppercasedCOMPARATOR, PRIORITY_DATABASE, PRIORITY_DEFAULT| Constructor and Description |
|---|
OracleDatabase()
Default constructor for an object that represents the Oracle Database DBMS.
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
canAccessDbaRecycleBin() |
String |
generateDatabaseFunctionValue(DatabaseFunction databaseFunction)
Some function names are placeholders that need to be replaced with the specific database value.
|
String |
generatePrimaryKeyName(String tableName) |
protected String |
getAutoIncrementClause(String generationType,
Boolean defaultOnNull)
Default implementation.
|
protected String |
getConnectionCatalogName() |
int |
getDatabaseMajorVersion() |
int |
getDatabaseMinorVersion() |
int |
getDataTypeMaxParameters(String dataTypeName) |
String |
getDateLiteral(String isoDate)
Returns an Oracle date literal with the same value as a string formatted using ISO 8601.
|
String |
getDbaRecycleBinWarning() |
String |
getDefaultCatalogName() |
protected String |
getDefaultDatabaseProductName() |
String |
getDefaultDriver(String url)
If this database understands the given url, return the default driver class name.
|
Integer |
getDefaultPort() |
int |
getIdentifierMaximumLength()
Returns the maximum number of bytes (NOT: characters) for an identifier.
|
String |
getJdbcCatalogName(CatalogAndSchema schema) |
String |
getJdbcSchemaName(CatalogAndSchema schema) |
int |
getPriority() |
String |
getShortName()
Returns an all-lower-case short name of the product.
|
String |
getSystemTableWhereClause(String tableNameColumn) |
Set<String> |
getUserDefinedTypes() |
boolean |
isCorrectDatabaseImplementation(DatabaseConnection conn)
Is this AbstractDatabase subclass the correct one to use for the given connection.
|
boolean |
isReservedWord(String objectName) |
boolean |
isSystemObject(DatabaseObject example) |
boolean |
isValidOracleIdentifier(String identifier,
Class<? extends DatabaseObject> type)
Tests if the given String would be a valid identifier in Oracle DBMS.
|
boolean |
jdbcCallsCatalogsSchemas() |
void |
setConnection(DatabaseConnection conn) |
boolean |
supportsAutoIncrement() |
boolean |
supportsInitiallyDeferrableColumns()
Returns whether this database support initially deferrable columns.
|
boolean |
supportsNotNullConstraintNames()
Does this database treat NOT NULL as an own kind of CONSTRAINT (in addition of simply being a column property)?
This will affect the CONSTRAINT clause SQL generators.
|
boolean |
supportsRestrictForeignKeys() |
boolean |
supportsSchemas()
Oracle supports catalogs in liquibase terms
|
boolean |
supportsSequences()
Does the database type support sequence.
|
boolean |
supportsTablespaces() |
ValidationErrors |
validate() |
addReservedWords, canCreateChangeLogTable, close, commit, correctObjectName, correctSchema, correctSchema, createsIndexesForForeignKeys, dataTypeIsNotModifiable, disableForeignKeyChecks, doesTagExist, dropDatabaseObjects, enableForeignKeyChecks, equals, escapeColumnName, escapeColumnName, escapeColumnNameList, escapeConstraintName, escapeDataTypeName, escapeIndexName, escapeObjectName, escapeObjectName, escapeSequenceName, escapeStringForDatabase, escapeTableName, escapeViewName, execute, executeRollbackStatements, executeRollbackStatements, executeStatements, filterRollbackVisitors, generateAutoIncrementBy, generateAutoIncrementStartWith, get, getAutoCommitMode, getAutoIncrementByClause, getAutoIncrementClause, getAutoIncrementClause, getAutoIncrementClosing, getAutoIncrementOpening, getAutoIncrementStartWithClause, getConcatSql, getConnection, getConnectionSchemaName, getConnectionSchemaNameCallStatement, getContainingObjects, getCurrentDateTimeFunction, getDatabaseChangeLogLockTableName, getDatabaseChangeLogTableName, getDatabaseProductName, getDatabaseProductVersion, getDateFunctions, getDateLiteral, getDateLiteral, getDateTimeLiteral, getDefaultFractionalDigitsForTimestamp, getDefaultScaleForNativeDataType, getDefaultSchema, getDefaultSchemaName, getFetchSize, getJdbcCatalogName, getJdbcSchemaName, getLineComment, getLiquibaseCatalogName, getLiquibaseSchemaName, getLiquibaseTablespaceName, getMaxFractionalDigitsForTimestamp, getName, getObjectQuotingStrategy, getOutputDefaultCatalog, getOutputDefaultSchema, getQuotingEndCharacter, getQuotingEndReplacement, getQuotingStartCharacter, getRanChangeSet, getRanChangeSetList, getRanDate, getRunStatus, getSchemaAndCatalogCase, getSchemaFromJdbcInfo, getSystemSchema, getSystemTables, getSystemViews, getTimeLiteral, getViewDefinition, hashCode, isAutoCommit, isCaseSensitive, isDateOnly, isDateTime, isDefaultCatalog, isDefaultSchema, isFunction, isLiquibaseObject, isSafeToRunUpdate, isSystemView, isTimeOnly, isTimestamp, markChangeSetExecStatus, mustQuoteObjectName, parseDate, quoteObject, removeRanStatus, requiresExplicitNullForColumns, requiresPassword, requiresUsername, resetInternalState, rollback, saveRollbackStatement, saveStatements, set, setAutoCommit, setCanCacheLiquibaseTableInfo, setCaseSensitive, setCurrentDateTimeFunction, setDatabaseChangeLogLockTableName, setDatabaseChangeLogTableName, setDefaultCatalogName, setDefaultSchemaName, setLiquibaseCatalogName, setLiquibaseSchemaName, setLiquibaseTablespaceName, setObjectQuotingStrategy, setOutputDefaultCatalog, setOutputDefaultSchema, startsWithNumeric, supportsBatchUpdates, supportsCatalogInObjectName, supportsCatalogs, supportsDDLInTransaction, supportsDropTableCascadeConstraints, supportsForeignKeyDisable, supportsPrimaryKeyNames, tag, toString, unescapeDataTypeName, unescapeDataTypeStringpublic static final String PRODUCT_NAME
protected final int SHORT_IDENTIFIERS_LENGTH
protected final int LONG_IDENTIFIERS_LEGNTH
public static final int ORACLE_12C_MAJOR_VERSION
public OracleDatabase()
public int getPriority()
public void setConnection(DatabaseConnection conn)
setConnection in interface DatabasesetConnection in class AbstractJdbcDatabasepublic String getShortName()
Databaseprotected String getDefaultDatabaseProductName()
getDefaultDatabaseProductName in class AbstractJdbcDatabasepublic int getDatabaseMajorVersion()
throws DatabaseException
getDatabaseMajorVersion in interface DatabasegetDatabaseMajorVersion in class AbstractJdbcDatabaseDatabaseExceptionpublic int getDatabaseMinorVersion()
throws DatabaseException
getDatabaseMinorVersion in interface DatabasegetDatabaseMinorVersion in class AbstractJdbcDatabaseDatabaseExceptionpublic Integer getDefaultPort()
public String getJdbcCatalogName(CatalogAndSchema schema)
getJdbcCatalogName in class AbstractJdbcDatabasepublic String getJdbcSchemaName(CatalogAndSchema schema)
getJdbcSchemaName in class AbstractJdbcDatabaseprotected String getAutoIncrementClause(String generationType, Boolean defaultOnNull)
AbstractJdbcDatabasegetAutoIncrementClause in class AbstractJdbcDatabasepublic String generatePrimaryKeyName(String tableName)
generatePrimaryKeyName in interface DatabasegeneratePrimaryKeyName in class AbstractJdbcDatabasepublic boolean supportsInitiallyDeferrableColumns()
Databasepublic boolean isReservedWord(String objectName)
isReservedWord in interface DatabaseisReservedWord in class AbstractJdbcDatabasepublic boolean supportsSequences()
AbstractJdbcDatabasesupportsSequences in interface DatabasesupportsSequences in class AbstractJdbcDatabasepublic boolean supportsSchemas()
supportsSchemas in interface DatabasesupportsSchemas in class AbstractJdbcDatabaseprotected String getConnectionCatalogName() throws DatabaseException
getConnectionCatalogName in class AbstractJdbcDatabaseDatabaseExceptionpublic boolean isCorrectDatabaseImplementation(DatabaseConnection conn) throws DatabaseException
DatabaseDatabaseExceptionpublic String getDefaultDriver(String url)
Databasepublic String getDefaultCatalogName()
getDefaultCatalogName in interface DatabasegetDefaultCatalogName in class AbstractJdbcDatabasepublic String getDateLiteral(String isoDate)
Returns an Oracle date literal with the same value as a string formatted using ISO 8601.
Convert an ISO8601 date string to one of the following results: to_date('1995-05-23', 'YYYY-MM-DD') to_date('1995-05-23 09:23:59', 'YYYY-MM-DD HH24:MI:SS')
Implementation restriction:
Currently, only the following subsets of ISO8601 are supported:
getDateLiteral in interface DatabasegetDateLiteral in class AbstractJdbcDatabasepublic boolean isSystemObject(DatabaseObject example)
isSystemObject in interface DatabaseisSystemObject in class AbstractJdbcDatabasepublic boolean supportsTablespaces()
public boolean supportsAutoIncrement()
supportsAutoIncrement in interface DatabasesupportsAutoIncrement in class AbstractJdbcDatabasepublic boolean supportsRestrictForeignKeys()
supportsRestrictForeignKeys in interface DatabasesupportsRestrictForeignKeys in class AbstractJdbcDatabasepublic int getDataTypeMaxParameters(String dataTypeName)
getDataTypeMaxParameters in interface DatabasegetDataTypeMaxParameters in class AbstractJdbcDatabasepublic boolean jdbcCallsCatalogsSchemas()
jdbcCallsCatalogsSchemas in class AbstractJdbcDatabasepublic String generateDatabaseFunctionValue(DatabaseFunction databaseFunction)
DatabasegenerateDatabaseFunctionValue in interface DatabasegenerateDatabaseFunctionValue in class AbstractJdbcDatabasedatabaseFunction - database function to check.public ValidationErrors validate()
validate in interface Databasevalidate in class AbstractJdbcDatabasepublic String getDbaRecycleBinWarning()
public boolean canAccessDbaRecycleBin()
public boolean supportsNotNullConstraintNames()
DatabasesupportsNotNullConstraintNames in interface DatabasesupportsNotNullConstraintNames in class AbstractJdbcDatabasepublic boolean isValidOracleIdentifier(String identifier, Class<? extends DatabaseObject> type)
public int getIdentifierMaximumLength()
Copyright © 2019 Liquibase.org. All rights reserved.