Class OracleDatabaseDialect
java.lang.Object
io.debezium.connector.jdbc.dialect.GeneralDatabaseDialect
io.debezium.connector.jdbc.dialect.oracle.OracleDatabaseDialect
- All Implemented Interfaces:
DatabaseDialect
A
DatabaseDialect implementation for Oracle.- Author:
- Chris Cranford
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic class -
Field Summary
Fields -
Constructor Summary
ConstructorsModifierConstructorDescriptionprivateOracleDatabaseDialect(JdbcSinkConnectorConfig config, org.hibernate.SessionFactory sessionFactory) -
Method Summary
Modifier and TypeMethodDescriptionprotected StringgetFormattedDate(TemporalAccessor value) Format a date.Format a date and time.getFormattedTime(TemporalAccessor value) Format a time.Format a timestamp.Format a timestamp with time zone.intGets the maximum length of a nationalized VARCHAR field in a primary key column.intGets the maximum length of a VARCHAR field in a primary key column.private StringgetUpsertIncomingClause(String fieldName, TableDescriptor table, SinkRecordDescriptor record) getUpsertStatement(TableDescriptor table, SinkRecordDescriptor record) Construct aUPSERTstatement specific for this dialect.protected booleanbooleanReturns whether the dialect permits negative scale.protected voidMethods inherited from class io.debezium.connector.jdbc.dialect.GeneralDatabaseDialect
addColumnDefaultValue, bindValue, columnNameFromField, columnNameFromField, columnQueryBindingFromField, getAlterTableStatement, getByteArrayFormat, getColumnNamingStrategy, getConfig, getCreateTableStatement, getDatabaseTimeZone, getDatabaseVersion, getDefaultDecimalPrecision, getDefaultTimestampPrecision, getDeleteStatement, getFormattedBoolean, getFormattedDateTimeWithNanos, getFormattedTimeWithTimeZone, getIdentifierHelper, getInsertStatement, getMaxVarbinaryLength, getQualifiedTableName, getQueryBindingWithValueCast, getSchemaType, getTableId, getTypeName, getTypeName, getTypeName, getUpdateStatement, getVersion, isTimeZoneSet, readTable, registerType, resolveMissingFields, shouldBindTimeWithTimeZoneAsDatabaseTimeZone, tableExists, toIdentifier, toIdentifierMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface io.debezium.connector.jdbc.dialect.DatabaseDialect
getAlterTableStatementFieldDelimiter, getMaxTimePrecision, getMaxTimestampPrecision, getTimeQueryBinding
-
Field Details
-
TO_DATE
- See Also:
-
TO_TIMESTAMP_FF9
- See Also:
-
TO_TIMESTAMP_FF6
- See Also:
-
TO_TIMESTAMP_FF9_TZ
- See Also:
-
-
Constructor Details
-
OracleDatabaseDialect
private OracleDatabaseDialect(JdbcSinkConnectorConfig config, org.hibernate.SessionFactory sessionFactory)
-
-
Method Details
-
getDatabaseTimeZoneQuery
- Overrides:
getDatabaseTimeZoneQueryin classGeneralDatabaseDialect
-
getDatabaseTimeZoneQueryResult
- Overrides:
getDatabaseTimeZoneQueryResultin classGeneralDatabaseDialect- Throws:
SQLException
-
registerTypes
protected void registerTypes()- Overrides:
registerTypesin classGeneralDatabaseDialect
-
getMaxVarcharLengthInKey
public int getMaxVarcharLengthInKey()Description copied from interface:DatabaseDialectGets the maximum length of a VARCHAR field in a primary key column.- Specified by:
getMaxVarcharLengthInKeyin interfaceDatabaseDialect- Overrides:
getMaxVarcharLengthInKeyin classGeneralDatabaseDialect- Returns:
- maximum varchar field length when participating in the primary key
-
getMaxNVarcharLengthInKey
public int getMaxNVarcharLengthInKey()Description copied from interface:DatabaseDialectGets the maximum length of a nationalized VARCHAR field in a primary key column.- Specified by:
getMaxNVarcharLengthInKeyin interfaceDatabaseDialect- Overrides:
getMaxNVarcharLengthInKeyin classGeneralDatabaseDialect- Returns:
- maximum varchar field length when participating in the primary key
-
isNegativeScaleAllowed
public boolean isNegativeScaleAllowed()Description copied from interface:DatabaseDialectReturns whether the dialect permits negative scale.- Specified by:
isNegativeScaleAllowedin interfaceDatabaseDialect- Overrides:
isNegativeScaleAllowedin classGeneralDatabaseDialect- Returns:
- true if the dialect permits using negative scale values
-
getUpsertStatement
Description copied from interface:DatabaseDialectConstruct aUPSERTstatement specific for this dialect.- Specified by:
getUpsertStatementin interfaceDatabaseDialect- Overrides:
getUpsertStatementin classGeneralDatabaseDialect- Parameters:
table- the current relational table model, should not benullrecord- the current sink record being processed, should not benull- Returns:
- the upsert SQL statement to be executed, never
null
-
isIdentifierUppercaseWhenNotQuoted
protected boolean isIdentifierUppercaseWhenNotQuoted()- Overrides:
isIdentifierUppercaseWhenNotQuotedin classGeneralDatabaseDialect
-
getFormattedDate
Description copied from interface:DatabaseDialectFormat a date.- Specified by:
getFormattedDatein interfaceDatabaseDialect- Overrides:
getFormattedDatein classGeneralDatabaseDialect- Parameters:
value- the value to tbe formatted, nevernull- Returns:
- the formatted string value
-
getFormattedTime
Description copied from interface:DatabaseDialectFormat a time.- Specified by:
getFormattedTimein interfaceDatabaseDialect- Overrides:
getFormattedTimein classGeneralDatabaseDialect- Parameters:
value- the value to be formatted, nevernull- Returns:
- the formatted string value
-
getFormattedDateTime
Description copied from interface:DatabaseDialectFormat a date and time.- Specified by:
getFormattedDateTimein interfaceDatabaseDialect- Overrides:
getFormattedDateTimein classGeneralDatabaseDialect- Parameters:
value- the value to be formatted, nevernull- Returns:
- the formatted string value
-
getFormattedTimestamp
Description copied from interface:DatabaseDialectFormat a timestamp.- Specified by:
getFormattedTimestampin interfaceDatabaseDialect- Overrides:
getFormattedTimestampin classGeneralDatabaseDialect- Parameters:
value- the value to be formatted, nevernull- Returns:
- the formatted string value
-
getFormattedTimestampWithTimeZone
Description copied from interface:DatabaseDialectFormat a timestamp with time zone.- Specified by:
getFormattedTimestampWithTimeZonein interfaceDatabaseDialect- Overrides:
getFormattedTimestampWithTimeZonein classGeneralDatabaseDialect- Parameters:
value- the value to be formatted, nevernull- Returns:
- the formatted string value.
-
getUpsertIncomingClause
private String getUpsertIncomingClause(String fieldName, TableDescriptor table, SinkRecordDescriptor record)
-