Class DialectDelegateWrapper
- All Implemented Interfaces:
FunctionContributor
,TypeContributor
,ConversionContext
-
Nested Class Summary
Nested classes/interfaces inherited from class org.hibernate.dialect.Dialect
Dialect.SizeStrategy, Dialect.SizeStrategyImpl
-
Field Summary
Fields inherited from class org.hibernate.dialect.Dialect
CLOSED_QUOTE, LEGACY_LOB_MERGE_STRATEGY, LOG_BASE2OF10, NEW_LOCATOR_LOB_MERGE_STRATEGY, QUOTE, STANDARD_MULTI_KEY_LOAD_SIZING_STRATEGY, STREAM_XFER_LOB_MERGE_STRATEGY
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionaddSqlHintOrComment
(String sql, QueryOptions queryOptions, boolean commentsEnabled) Modify the SQL, adding hints or comments, if necessaryvoid
appendArrayLiteral
(SqlAppender appender, Object[] literal, JdbcLiteralFormatter<Object> elementFormatter, WrapperOptions wrapperOptions) Append an array literal with the given elements to the givenSqlAppender
.void
appendBinaryLiteral
(SqlAppender appender, byte[] bytes) Append a binary literal to the givenSqlAppender
.void
appendBooleanValueString
(SqlAppender appender, boolean bool) Append the SQL literal expression representing the given boolean value to the givenSqlAppender
.void
appendDatetimeFormat
(SqlAppender appender, String format) Translate the given datetime format string from the pattern language defined by Java'sDateTimeFormatter
to whatever pattern language is understood by the native datetime formatting function for this database (often theto_char()
function).void
appendDateTimeLiteral
(SqlAppender appender, TemporalAccessor temporalAccessor, TemporalType precision, TimeZone jdbcTimeZone) Append a datetime literal representing the givenjava.time
value to the givenSqlAppender
.void
appendDateTimeLiteral
(SqlAppender appender, Calendar calendar, TemporalType precision, TimeZone jdbcTimeZone) Append a datetime literal representing the givenCalendar
value to the givenSqlAppender
.void
appendDateTimeLiteral
(SqlAppender appender, Date date, TemporalType precision, TimeZone jdbcTimeZone) Append a datetime literal representing the givenDate
value to the givenSqlAppender
.void
appendIntervalLiteral
(SqlAppender appender, Duration literal) Append a literal SQLinterval
representing the given JavaDuration
.void
appendLiteral
(SqlAppender appender, String literal) Append a literal string to the givenSqlAppender
.appendLockHint
(LockOptions lockOptions, String tableName) Some dialects support an alternative means toSELECT FOR UPDATE
, whereby a "lock hint" is appended to the table name in thefrom
clause.void
appendUUIDLiteral
(SqlAppender appender, UUID literal) Append a literal SQLuuid
representing the given JavaUUID
.applyLocksToSql
(String sql, LockOptions aliasedLockOptions, Map<String, String[]> keyColumnNames) Modifies the given SQL, applying the appropriate updates for the specified lock modes and key columns.void
augmentPhysicalTableTypes
(List<String> tableTypesList) void
augmentRecognizedTableTypes
(List<String> tableTypesList) buildIdentifierHelper
(IdentifierHelperBuilder builder, DatabaseMetaData dbMetaData) TheIdentifierHelper
indicated by this dialect for handling identifier conversions.An instance ofSQLExceptionConversionDelegate
for interpreting dialect-specific error or SQLState codes.boolean
Does thetruncate table
statement accept multiple tables?boolean
Does this dialect support creating and dropping catalogs?boolean
Does this dialect support creating and dropping schema?boolean
Is there some way to disable foreign key constraint checking while truncating tables? (If there's no way to do it, and if we can't batch truncate, we must drop and recreate the constraints instead.)castPattern
(CastType from, CastType to) Obtain a pattern for the SQL equivalent to acast()
function call.castType
(int sqlTypeCode) The SQL type to use incast( ... as ... )
expressions when casting to the target type represented by the given JDBC type code.protected final void
char
The character specific to this dialect used to close a quoted identifier.columnType
(int sqlTypeCode) void
contribute
(TypeContributions typeContributions, ServiceRegistry serviceRegistry) Contribute typesvoid
contributeFunctions
(FunctionContributions functionContributions) Contribute functionsvoid
contributeTypes
(TypeContributions typeContributions, ServiceRegistry serviceRegistry) A callback which allows theDialect
to contribute types.createOptionalTableUpdateOperation
(EntityMutationTarget mutationTarget, OptionalTableUpdate optionalTableUpdate, SessionFactoryImplementor factory) Create aMutationOperation
for a updating an optional tableTranslation of the HQLlocal_time
function, which maps to the Java typeLocalTime
which is a time with no time zone.Translation of the HQLlocal_datetime
function, which maps to the Java typeLocalDateTime
which is a datetime with no time zone.Translation of the HQL/JPQLcurrent_time
function, which maps to the Java typeTime
which is a time with no time zone.Translation of the HQL/JPQLcurrent_timestamp
function, which maps to the Java typeTimestamp
which is a datetime with no time zone.Translation of the HQLoffset_datetime
function, which maps to the Java typeOffsetDateTime
which is a datetime with a time zone.A defaultScrollMode
to be used byQuery.scroll()
.boolean
For the underlying database, isREAD_COMMITTED
isolation implemented by forcing readers to wait for write locks to be released?boolean
For the underlying database, isREPEATABLE_READ
isolation implemented by forcing writers to wait for read locks to be released?boolean
Do we need to drop constraints before dropping tables in this dialect?boolean
equivalentTypes
(int typeCode1, int typeCode2) Do the given JDBC type codes, as defined inTypes
represent essentially the same type in this dialect of SQL?static String
escapeComment
(String comment) extractPattern
(TemporalUnit unit) Obtain a pattern for the SQL equivalent to anextract()
function call.static Dialect
extractRealDialect
(Dialect dialect) Extract the wrapped dialect, recursively until a non-wrapped implementation is found; this is useful for all the code needing to know "of which type" the underlying implementation actually is.boolean
Must LOB values occur last in inserts and updates?generatedAs
(String generatedAs) Thegenerated as
clause, or similar, for generated column declarations in DDL statements.The subcommand of thealter table
command used to add a column to a table, usuallyadd column
oradd
.The syntax for the suffix used to add a column to a table.getAddForeignKeyConstraintString
(String constraintName, String foreignKeyDefinition) The syntax used to add a foreign key constraint to a table, given the definition of the foreign key as a string.getAddForeignKeyConstraintString
(String constraintName, String[] foreignKey, String referencedTable, String[] primaryKey, boolean referencesPrimaryKey) The syntax used to add a foreign key constraint to a table, with the referenced key columns explicitly specified.getAddPrimaryKeyConstraintString
(String constraintName) The syntax used to add a primary key constraint to a table.How does this dialect support aggregate types likeSqlTypes.STRUCT
.getAlterColumnTypeString
(String columnName, String columnType, String columnDefinition) The fragment of analter table
command which modifies a column type, or null if column types cannot be modified.getAlterTableString
(String tableName) The command used to alter a table with the given name, usuallyalter table tab_name
oralter table tab_name if exists
.getArrayTypeName
(String javaElementTypeName, String elementTypeName, Integer maxLength) The SQL type name for the array type with elements of the given type name.The strategy used to determine the appropriate number of keys to load in a single SQL query with batch-fetch loading.TheCallableStatementSupport
for this database.The keyword that specifies that adrop table
operation should be cascaded to its constraints, typically" cascade"
where the leading space is required, or the empty string if there is no such keyword in this dialect.The name of the SQL operator that performs case-insensitiveLIKE
comparisons.getCheckCondition
(String columnName, long min, long max) Render a SQL check condition for a column that represents an enumerated value.getCheckCondition
(String columnName, String[] values) Render a SQL check condition for a column that represents an enumerated value by its string representation or a given list of values (with NULL value allowed).AColumnAliasExtractor
, usually justResultSetMetaData.getColumnLabel(int)
.getColumnComment
(String comment) Get the comment into a form supported for column definition.String[]
getCreateCatalogCommand
(String catalogName) Get the SQL command used to create the named catalog.getCreateIndexString
(boolean unique) The command used to create an index, usuallycreate index
orcreate unique index
.getCreateIndexTail
(boolean unique, List<Column> columns) A string to be appended to the end of thecreate index
command, usually to specify thatnull
values are to be considered distinct.Slight variation onDialect.getCreateTableString()
.String[]
getCreateSchemaCommand
(String schemaName) Get the SQL command used to create the named schema.The command used to create a table, usuallycreate table
.getCreateTemporaryTableColumnAnnotation
(int sqlTypeCode) Annotation to be appended to the end of each COLUMN clause for temporary tables.An arbitrary extension to append to the end of the UDTcreate type
command.The kind of user-defined type to create, or the empty string if this does not need to be specified.Get the SQL command used to retrieve the current schema name.The command used to retrieve the current timestamp from the database.int
This is the default precision for a generated column of exact numeric typeDECIMAL
orNUMERIC
mapped to aBigInteger
orBigDecimal
.long
boolean
The default value to use for the configuration property "hibernate.jdbc.lob.non_contextual_creation".Retrieve a set of default Hibernate properties for this database.int
The default value to use for the configuration property "hibernate.jdbc.batch_size".int
This is the default precision for a generated column of typeTIMESTAMP
mapped to aTimestamp
orLocalDateTime
.boolean
The default value to use for the configuration property "hibernate.jdbc.use_get_generated_keys".A SQL statement that temporarily disables foreign key constraint checking for all tables.getDisableConstraintStatement
(String tableName, String name) A SQL statement that temporarily disables checking of the given foreign key constraint.int
This is the default precision for a generated column mapped to a JavaDouble
ordouble
.String[]
getDropCatalogCommand
(String catalogName) Get the SQL command used to drop the named catalog.The subcommand of thealter table
command used to drop a foreign key constraint, usuallydrop constraint
.String[]
getDropSchemaCommand
(String schemaName) Get the SQL command used to drop the named schema.getDropTableString
(String tableName) The command used to drop a table with the given name, usuallydrop table tab_name
.The subcommand of thealter table
command used to drop a unique key constraint.A SQL statement that re-enables foreign key constraint checking for all tables.getEnableConstraintStatement
(String tableName, String name) A SQL statement that re-enables checking of the given foreign key constraint.getEnumTypeDeclaration
(String name, String[] values) If this database has a special MySQL-styleenum
column type, return the type declaration for the given enumeration of values.getFallbackSchemaManagementTool
(Map<String, Object> configurationValues, ServiceRegistryImplementor registry) TheSchemaManagementTool
to use if none is explicitly specified.getFallbackSqmInsertStrategy
(EntityMappingType entityDescriptor, RuntimeModelCreationContext runtimeModelCreationContext) TheSqmMultiTableInsertStrategy
to use when not specified byQueryEngineOptions.getCustomSqmMultiTableInsertStrategy()
.getFallbackSqmMutationStrategy
(EntityMappingType entityDescriptor, RuntimeModelCreationContext runtimeModelCreationContext) TheSqmMultiTableMutationStrategy
to use when not specified byQueryEngineOptions.getCustomSqmMultiTableMutationStrategy()
.int
This is the default precision for a generated column mapped to a JavaFloat
orfloat
.Retrieves theFOR UPDATE NOWAIT
syntax specific to this dialect.getForUpdateNowaitString
(String aliases) Get theFOR UPDATE OF column_list NOWAIT
fragment appropriate for this dialect, given the aliases of the columns to be write locked.Retrieves theFOR UPDATE SKIP LOCKED
syntax specific to this dialect.getForUpdateSkipLockedString
(String aliases) Get theFOR UPDATE OF column_list SKIP LOCKED
fragment appropriate for this dialect, given the aliases of the columns to be write locked.Get the string to append toSELECT
statements to acquire pessimistic UPGRADE locks for this dialect.getForUpdateString
(String aliases) Get theFOR UPDATE OF column_list
fragment appropriate for this dialect, given the aliases of the columns to be write locked.getForUpdateString
(String aliases, LockOptions lockOptions) Get theFOR UPDATE OF
orFOR SHARE OF
fragment appropriate for this dialect, given the aliases of the columns to be locked.getForUpdateString
(LockMode lockMode) Given aLockMode
, determine the appropriatefor update
fragment to use to obtain the lock.getForUpdateString
(LockOptions lockOptions) Given a set ofLockOptions
(lock level, timeout), determine the appropriatefor update
fragment to use to obtain the lock.long
The "native" precision for arithmetic with datetimes and day-to-second durations.Determine how selected items are referenced in thegroup by
clause.Get the appropriateIdentityColumnSupport
for this dialect.int
Return the limit that the underlying database places on the number of elements in anIN
predicate.The keywords of this SQL dialect.Obtain aLimitHandler
that implements pagination support forQuery.setMaxResults(int)
andQuery.setFirstResult(int)
.Get theLobMergeStrategy
to use,Dialect.NEW_LOCATOR_LOB_MERGE_STRATEGY
by default.getLockingStrategy
(Lockable lockable, LockMode lockMode) ALockingStrategy
which is able to acquire a database-level lock with the specified level.getLockRowIdentifier
(LockMode lockMode) Obtain aRowLockStrategy
for the givenLockMode
.The name of the SQL function that transforms a string to lowercase, almost alwayslower
.int
What is the maximum length Hibernate can use for generated aliases?int
What is the maximum identifier length supported by this dialect?int
The longest possible length of aTypes.NVARCHAR
-like column.int
The biggest size value that can be supplied as argument to aTypes.NVARCHAR
-like type.int
The longest possible length of aTypes.VARBINARY
-like column.int
The biggest size value that can be supplied as argument to aTypes.VARBINARY
-like type.int
The longest possible length of aTypes.VARCHAR
-like column.int
The biggest size value that can be supplied as argument to aTypes.VARCHAR
-like type.Get the version of the SQL dialect that is the minimum supported by this implementation.The strategy used to determine the appropriate number of keys to load in a single SQL query with multi-key loading.Determines whether this database requires the use of explicitly nationalized character (Unicode) data types.The name identifying the "native" id generation strategy for this dialect.Support for native parameter markers.Deprecated.The keyword used to specify a nullable column, usually""
, but sometimes" null"
.getNullColumnString
(String columnType) The keyword used to specify a nullable column of the given SQL type.Returns the default ordering of null.int
Return the limit that the underlying database places on the number of parameters that can be defined for a PreparedStatement.int
The JDBC type code to use for mapping properties of basic Java array orCollection
types.int
The JDBC type code to use for mapping properties of Java typeboolean
.getQueryHintString
(String query, String hints) Apply a hint to the given SQL query.getQueryHintString
(String query, List<String> hintList) Apply a hint to the given SQL query.Get theselect
command used retrieve the names of all sequences.getReadLockString
(int timeout) Get the string to append toSELECT
statements to acquire READ locks for this dialect.getReadLockString
(String aliases, int timeout) Get the string to append toSELECT
statements to acquire READ locks for this dialect, given the aliases of the columns to be read locked.The row lock strategy to use for read locks.getResultSet
(CallableStatement statement) Given a callable statement previously processed byDialect.registerResultSetOutParameter(java.sql.CallableStatement, int)
, extract theResultSet
from theOUT
parameter.getResultSet
(CallableStatement statement, int position) Given a callable statement previously processed byDialect.registerResultSetOutParameter(java.sql.CallableStatement, int)
, extract theResultSet
from the positionalOUT
parameter.getResultSet
(CallableStatement statement, String name) Given a callable statement previously processed byDialect.registerResultSetOutParameter(java.sql.CallableStatement, int)
, extract theResultSet
from the namedOUT
parameter.getRowIdColumnString
(String rowId) If this dialect requires that therowid
column be declared explicitly, return the DDL column definition.Get the strategy for determining the schema name from a JDBCConnection
, usuallyDefaultSchemaNameResolver
.getSelectClauseNullString
(int sqlType, TypeConfiguration typeConfiguration) Given a JDBC type code, return the expression for a literal null value of that type, to use in aselect
clause.Get the command used to select a GUID from the database.ASequenceInformationExtractor
which is able to extractSequenceInformation
from the JDBC result set returned whenDialect.getQuerySequencesString()
is executed.Get the appropriateSequenceSupport
for this dialect.A customDialect.SizeStrategy
for column types.The kind of temporary tables that are supported on this database.Get a schemaCleaner
, usuallyStandardTableCleaner
.getTableComment
(String comment) Get the comment into a form supported for table definition.Get aTableMigrator
, usuallyStandardTableMigrator
.An arbitrary fragment appended to the end of thecreate table
statement.The action to take after finishing use of a temporary table.The action to take before beginning use of a temporary table.The command to create a temporary table.An arbitrary SQL fragment appended to the end of the statement to create a temporary table, specifying dialect-specific options, ornull
if there are no options to specify.The sort of transaction handling to use when creating or dropping temporary tables.The command to drop a temporary table.Get aTemporaryTableExporter
, usuallyStandardTemporaryTableExporter
.The command to truncate a temporary table.How the dialect supports time zone types likeTypes.TIMESTAMP_WITH_TIMEZONE
.getTruncateTableStatement
(String tableName) A SQL statement that truncates the given table.String[]
getTruncateTableStatements
(String[] tableNames) A SQL statement or statements that truncate the given tables.Get theUniqueDelegate
supported by this dialectgetUserDefinedTypeComment
(String comment) Get the comment into a form supported for UDT definition.Get the version of the SQL dialect that is the target of this instance.AViolatedConstraintNameExtractor
for extracting the name of a violated constraint from aSQLException
.Exposed so to allow code needing to know the implementation.getWriteLockString
(int timeout) Get the string to append toSELECT
statements to acquire pessimistic WRITE locks for this dialect.getWriteLockString
(String aliases, int timeout) Get the string to append toSELECT
statements to acquire WRITE locks for this dialect, given the aliases of the columns to be write locked.The row lock strategy to use for write locks.boolean
Does this dialect support theALTER TABLE
syntax?boolean
Is an explicit column type required forgenerated as
columns?boolean
Does the database/driver have bug in deleting rows that refer to other rows being deleted in the same query?protected final void
Set appropriate default values for configuration properties.void
initializeFunctionRegistry
(FunctionContributions functionContributions) Initialize the given registry with any dialect-specific functions.inlineLiteral
(String literal) Deprecated, for removal: This API element is subject to removal in a future version.boolean
Deprecated.boolean
Is the command returned byDialect.getCurrentTimestampSelectString()
treated as callable?boolean
Return whether the dialect considers an empty string value to be null.boolean
Is JDBC statement warning logging enabled by default?boolean
Deprecated, for removal: This API element is subject to removal in a future version.char
The character specific to this dialect used to begin a quoted identifier.int
ordinal()
Determines order in which the contributions will be applied (lowest ordinal first).prependComment
(String sql, String comment) Prepend a comment to the given SQL fragment.boolean
Do we need to qualify index names with the schema name?Apply dialect-specific quoting if the given name is quoted using backticks.void
registerColumnTypes
(TypeContributions typeContributions, ServiceRegistry serviceRegistry) Register ANSI-standard column types using the length limits defined byDialect.getMaxVarcharLength()
,Dialect.getMaxNVarcharLength()
, andDialect.getMaxVarbinaryLength()
.protected final void
Register the reserved words of ANSI-standard SQL as keywords.void
registerKeyword
(String word) Register a keyword.void
Register the reserved words reported by the JDBC driver as keywords.int
registerResultSetOutParameter
(CallableStatement statement, int position) Registers a parameter capable of returning aResultSet
by position, either anOUT
parameter, or aREF_CURSOR
parameter as defined in Java 8.int
registerResultSetOutParameter
(CallableStatement statement, String name) Registers a parameter capable of returning aResultSet
by name, either anOUT
parameter, or aREF_CURSOR
parameter as defined in Java 8.boolean
Does this dialect/database require casting of non-string arguments in theconcat()
function?boolean
Does this dialect require that integer divisions be wrapped incast()
calls to tell the db parser the expected type.boolean
IfDialect.supportsTupleCounts()
is true, does this dialect require the tuple to be delimited with parentheses?boolean
IfDialect.supportsTupleDistinctCounts()
is true, does this dialect require the tuple to be delimited with parentheses?resolveSqlTypeCode
(String typeName, String baseTypeName, TypeConfiguration typeConfiguration) Resolves theSqlTypes
type code for the given column type name as reported by the database and the base type name (i.e.resolveSqlTypeCode
(String columnTypeName, TypeConfiguration typeConfiguration) Resolves theSqlTypes
type code for the given column type name as reported by the database, ornull
if it can't be resolved.resolveSqlTypeDescriptor
(String columnTypeName, int jdbcTypeCode, int precision, int scale, JdbcTypeRegistry jdbcTypeRegistry) Assigns an appropriateJdbcType
to a column of a JDBC result set based on the column type name, JDBC type code, precision, and scale.int
resolveSqlTypeLength
(String columnTypeName, int jdbcTypeCode, int precision, int scale, int displaySize) Determine the length/precision of a column based on information in the JDBCResultSetMetaData
.The name of arowid
-like pseudo-column which acts as a high-performance row locator, or null if this dialect has no such pseudo-column.int
The JDBC type code of therowid
-like pseudo-column which acts as a high-performance row locator.boolean
Does this dialect support modifying the type of an existing column?boolean
Does this dialect support using a JDBC bind parameter as an argument to a function or procedure call?boolean
boolean
Does this dialect supporton delete
actions in foreign key definitions?boolean
Does this dialect support case-insensitiveLIKE
comparisons?boolean
Does this dialect support definition of cascade delete constraints which can cause circular chains?boolean
Does this dialect support column-level check constraints?boolean
Does this dialect support commenting on tables and columns?boolean
Does this dialect support some way to retrieve the current timestamp value from the database?boolean
Does this dialect support some kind ofdistinct from
predicate?boolean
Does the dialect support an exists statement in the select clause?boolean
"Expected" LOB usage pattern is such that I can perform an insert via prepared statement with a parameter binding for a LOB value without crazy casting to JDBC driver implementation-specific classes.boolean
Does this dialect support the givenFETCH
clause type.boolean
Whether the database supports adding a fractional interval to a timestamp, for exampletimestamp + 0.5 second
.boolean
For analter table
, can the phraseif exists
be applied?boolean
For dropping a constraint with analter table
, can the phraseif exists
be applied after the constraint name?boolean
For dropping a table, can the phraseif exists
be applied after the table name?boolean
For dropping a type, can the phraseif exists
be applied after the type name?boolean
For dropping a constraint with analter table
statement, can the phraseif exists
be applied before the constraint name?boolean
For dropping a table, can the phraseif exists
be applied before the table name?boolean
For dropping a type, can the phraseif exists
be applied before the type name?boolean
Does this dialect fully support returning arbitrary generated column values after execution of aninsert
statement, using native SQL syntax?boolean
Does this dialect fully support returning arbitrary generated column values after execution of aninsert
statement, using the JDBC methodConnection.prepareStatement(String, String[])
.boolean
supportsJdbcConnectionLobCreation
(DatabaseMetaData databaseMetaData) Check whether the JDBCConnection
supports creating LOBs viaConnection.createBlob()
,Connection.createNClob()
, orConnection.createClob()
.boolean
Does this dialect support the SQLlateral
keyword or a proprietary alternative?boolean
Does the dialect support propagating changes to LOB values back to the database? Talking about mutating the internal value of the locator, as opposed to supplying a new locator instance.boolean
Does this dialect support specifying timeouts when requesting locks.boolean
Check whether the JDBC driver allows setting LOBs viaPreparedStatement.setBytes(int, byte[])
,PreparedStatement.setNString(int, String)
, orPreparedStatement.setString(int, String)
APIs.boolean
supportsNamedParameters
(DatabaseMetaData databaseMetaData) boolean
Is theINSERT
statement is allowed to contain no columns?boolean
Does this dialect support insert, update, and delete statements with Common Table Expressions (CTEs)?boolean
Does this dialect supportNO_WAIT
timeout.boolean
Does this dialect supportnulls first
andnulls last
?boolean
Does this dialect supportoffset
in subqueries?boolean
Does this dialect support theorder by
clause in subqueries?boolean
Does this dialect support references to result variables (i.e, select items) by column positions (1-origin) as defined by the select clause?boolean
Does this dialect supportFOR UPDATE
in conjunction with outer-joined rows?boolean
Deprecated, for removal: This API element is subject to removal in a future version.boolean
Does is dialect supportpartition by
?boolean
Whether a predicate likea > 0
can appear in an expression context, for example, in aselect
list item.boolean
Does this dialect/database support recursive CTEs?boolean
Does this dialect support asking the result set its positioning information on forward-only cursors?boolean
Does this dialect supportSKIP_LOCKED
timeout.boolean
Does this database have native support for ANSI SQL standard arrays which are expressed in terms of the element type name:integer array
.boolean
Does this dialect have an ANSI SQLcurrent_timestamp
function?boolean
Does this dialect support subqueries in theselect
clause?boolean
Does this dialect support referencing the table being mutated in a subquery? The "table being mutated" is the table referenced in an update or delete query.boolean
Is a subselect supported as the left-hand side (LHS) of anIN
predicates?boolean
Does this dialect support table-level check constraints?boolean
Does this dialect supports timezone offsets in temporal literals.boolean
Does this database support primary keys for temporary tables?boolean
Does this database have some sort of support for temporary tables?boolean
Does this dialect support truncation of values to a specified length via acast
?boolean
Does this dialect supportcount(a,b)
?boolean
Does this dialect supportcount(distinct a,b)
?boolean
Is it supported to materialize a LOB locator outside the transaction in which it was created?boolean
Does this dialect supportUNION ALL
?boolean
Does this dialect supportUNION
in a subquery.boolean
Does this dialect supportvalues
lists of formVALUES (1), (2), (3)
?boolean
Does this dialect supportvalues
lists of formVALUES (1), (2), (3)
in insert statements?boolean
Does this dialect supportWAIT
timeout.boolean
Does this dialect support window functions likerow_number() over (..)
?timestampaddPattern
(TemporalUnit unit, TemporalType temporalType, IntervalType intervalType) Obtain a pattern for the SQL equivalent to atimestampadd()
function call.timestampdiffPattern
(TemporalUnit unit, TemporalType fromTemporalType, TemporalType toTemporalType) Obtain a pattern for the SQL equivalent to atimestampdiff()
function call.toBooleanValueString
(boolean bool) The SQL literal expression representing the given boolean value.toQuotedIdentifier
(String name) Apply dialect-specific quoting.toString()
transformSelectString
(String select) Meant as a means for end users to affect the select strings being sent to the database and perhaps manipulate them in some fashion.Return the name used to identify the given unit of duration as an argument to#timestampadd()
or#timestampdiff()
, or of this dialect's equivalent functions.Return the name used to identify the given field as an argument to theextract()
function, or of this dialect's equivalent function.trimPattern
(TrimSpec specification, boolean isWhitespace) Obtain a pattern for the SQL equivalent to atrim()
function call.trimPattern
(TrimSpec specification, char character) Obtain a pattern for the SQL equivalent to atrim()
function call.boolean
Should BLOB, CLOB, and NCLOB be created solely using respectivelyConnection.createBlob()
,Connection.createClob()
, andConnection.createNClob()
.boolean
useFollowOnLocking
(String sql, QueryOptions queryOptions) Some dialects have trouble applying pessimistic locking depending upon what other query options are specified (paging, ordering, etc).boolean
Should LOBs (both BLOB and CLOB) be bound using stream operations, that is, usingPreparedStatement.setBinaryStream(int, java.io.InputStream, int)
).boolean
Whether to switch: fromVARCHAR
-like types toSqlTypes.MATERIALIZED_CLOB
types when the requested size for a type exceeds theDialect.getMaxVarcharCapacity()
, fromNVARCHAR
-like types toSqlTypes.MATERIALIZED_NCLOB
types when the requested size for a type exceeds theDialect.getMaxNVarcharCapacity()
, and fromVARBINARY
-like types toSqlTypes.MATERIALIZED_BLOB
types when the requested size for a type exceeds theDialect.getMaxVarbinaryCapacity()
.Methods inherited from class org.hibernate.dialect.Dialect
doesRoundTemporalOnOverflow, getBeforeDropStatement, getCheckCondition, getCheckCondition, getCheckCondition, getCreateEnumTypeCommand, getCreateEnumTypeCommand, getCrossReferenceParentTableFilter, getDefaultIntervalSecondScale, getDmlTargetColumnQualifierSupport, getDropEnumTypeCommand, getDropEnumTypeCommand, getEnumTypeDeclaration, getFunctionalDependencyAnalysisSupport, getTimeoutInSeconds, isLob, quoteCollation, supportsBatchUpdates, supportsConflictClauseForInsertCTE, supportsFromClauseInUpdate, supportsInsertReturningRowId, supportsIsTrue, supportsNationalizedMethods, supportsRefCursors, supportsUpdateReturning, unquoteGetGeneratedKeys, useArrayForMultiValuedParameters, useCrossReferenceForeignKeys
-
Field Details
-
wrapped
-
-
Constructor Details
-
DialectDelegateWrapper
-
-
Method Details
-
extractRealDialect
Extract the wrapped dialect, recursively until a non-wrapped implementation is found; this is useful for all the code needing to know "of which type" the underlying implementation actually is.- Parameters:
dialect
- the Dialect to unwrap- Returns:
- a Dialect implementation which is not a DialectDelegateWrapper; could be the same as the argument.
-
getWrappedDialect
Exposed so to allow code needing to know the implementation.- Returns:
- the wrapped Dialect
-
checkVersion
protected final void checkVersion()- Overrides:
checkVersion
in classDialect
-
registerDefaultKeywords
protected final void registerDefaultKeywords()Description copied from class:Dialect
Register the reserved words of ANSI-standard SQL as keywords.- Overrides:
registerDefaultKeywords
in classDialect
- See Also:
-
initDefaultProperties
protected final void initDefaultProperties()Description copied from class:Dialect
Set appropriate default values for configuration properties.This default implementation sets "hibernate.jdbc.batch_size", "hibernate.jdbc.lob.non_contextual_creation", and "hibernate.jdbc.use_get_generated_keys" to defaults determined by calling
Dialect.getDefaultStatementBatchSize()
,Dialect.getDefaultNonContextualLobCreation()
, andDialect.getDefaultUseGetGeneratedKeys()
.An implementation may set additional configuration properties, but this is discouraged.
- Overrides:
initDefaultProperties
in classDialect
-
registerColumnTypes
public void registerColumnTypes(TypeContributions typeContributions, ServiceRegistry serviceRegistry) Description copied from class:Dialect
Register ANSI-standard column types using the length limits defined byDialect.getMaxVarcharLength()
,Dialect.getMaxNVarcharLength()
, andDialect.getMaxVarbinaryLength()
.This method is always called when a
Dialect
is instantiated.- Overrides:
registerColumnTypes
in classDialect
-
columnType
Description copied from class:Dialect
The database column type name for a given JDBC type code defined inTypes
orSqlTypes
. This default implementation returns the ANSI-standard type name.This method may be overridden by concrete
Dialect
s as an alternative toDialect.registerColumnTypes(TypeContributions, ServiceRegistry)
for simple registrations.Note that:
- Implementations of this method are expected to define a
sensible mapping for
Types.NCLOB
Types.NCHAR
, andTypes.NVARCHAR
. On some database, these types are simply remapped toCLOB
,CHAR
, andVARCHAR
. - Mappings for
Types.TIMESTAMP
andTypes.TIMESTAMP_WITH_TIMEZONE
should support explicit specification of precision if possible. - As specified by
DdlTypeRegistry.getDescriptor(int)
, this method never receivesTypes.LONGVARCHAR
,Types.LONGNVARCHAR
, norTypes.LONGVARBINARY
, which are considered synonyms for their non-LONG
counterparts. - On the other hand, the types
SqlTypes.LONG32VARCHAR
,SqlTypes.LONG32NVARCHAR
, andSqlTypes.LONG32VARBINARY
are not synonyms, and implementations of this method must define sensible mappings, for example to database-nativeTEXT
orCLOB
types.
- Overrides:
columnType
in classDialect
- Parameters:
sqlTypeCode
- a SQLtype code
- Returns:
- a column type name, with
$l
,$p
,$s
placeholders for length, precision, scale - See Also:
- Implementations of this method are expected to define a
sensible mapping for
-
castType
Description copied from class:Dialect
The SQL type to use incast( ... as ... )
expressions when casting to the target type represented by the given JDBC type code. -
registerKeywords
Description copied from class:Dialect
Register the reserved words reported by the JDBC driver as keywords.- Overrides:
registerKeywords
in classDialect
- See Also:
-
getVersion
Description copied from class:Dialect
Get the version of the SQL dialect that is the target of this instance.- Overrides:
getVersion
in classDialect
-
getMinimumSupportedVersion
Description copied from class:Dialect
Get the version of the SQL dialect that is the minimum supported by this implementation.- Overrides:
getMinimumSupportedVersion
in classDialect
-
resolveSqlTypeCode
Description copied from class:Dialect
Resolves theSqlTypes
type code for the given column type name as reported by the database, ornull
if it can't be resolved.- Overrides:
resolveSqlTypeCode
in classDialect
-
resolveSqlTypeCode
public Integer resolveSqlTypeCode(String typeName, String baseTypeName, TypeConfiguration typeConfiguration) Description copied from class:Dialect
Resolves theSqlTypes
type code for the given column type name as reported by the database and the base type name (i.e. without precision, length and scale), ornull
if it can't be resolved.- Overrides:
resolveSqlTypeCode
in classDialect
-
getNativeParameterMarkerStrategy
Description copied from class:Dialect
Support for native parameter markers. This is generally dependent on both the database and the driver.- Overrides:
getNativeParameterMarkerStrategy
in classDialect
- Returns:
- May return
null
to indicate that the JDBC standard strategy should be used
-
resolveSqlTypeDescriptor
public JdbcType resolveSqlTypeDescriptor(String columnTypeName, int jdbcTypeCode, int precision, int scale, JdbcTypeRegistry jdbcTypeRegistry) Description copied from class:Dialect
Assigns an appropriateJdbcType
to a column of a JDBC result set based on the column type name, JDBC type code, precision, and scale.- Overrides:
resolveSqlTypeDescriptor
in classDialect
- Parameters:
columnTypeName
- the column type namejdbcTypeCode
- thetype code
precision
- the precision or 0scale
- the scale or 0- Returns:
- an appropriate instance of
JdbcType
-
resolveSqlTypeLength
public int resolveSqlTypeLength(String columnTypeName, int jdbcTypeCode, int precision, int scale, int displaySize) Description copied from class:Dialect
Determine the length/precision of a column based on information in the JDBCResultSetMetaData
. Note that what JDBC reports as a "precision" might actually be the column length.- Overrides:
resolveSqlTypeLength
in classDialect
- Parameters:
columnTypeName
- the name of the column typejdbcTypeCode
- the JDBC type code of the column typeprecision
- the (numeric) precision or (character) length of the columnscale
- the scale of a numeric columndisplaySize
- the display size of the column- Returns:
- the precision or length of the column
-
getEnumTypeDeclaration
Description copied from class:Dialect
If this database has a special MySQL-styleenum
column type, return the type declaration for the given enumeration of values.If the database has no such type, return
null
.- Overrides:
getEnumTypeDeclaration
in classDialect
values
- the enumerated values of the type- Returns:
- the DDL column type declaration
-
getCheckCondition
Description copied from class:Dialect
Render a SQL check condition for a column that represents an enumerated value by its string representation or a given list of values (with NULL value allowed).- Overrides:
getCheckCondition
in classDialect
- Returns:
- a SQL expression that will occur in a
check
constraint
-
getCheckCondition
Description copied from class:Dialect
Render a SQL check condition for a column that represents an enumerated value. by its ordinal representation.- Overrides:
getCheckCondition
in classDialect
- Returns:
- a SQL expression that will occur in a
check
constraint
-
contributeFunctions
Description copied from interface:FunctionContributor
Contribute functions- Specified by:
contributeFunctions
in interfaceFunctionContributor
- Overrides:
contributeFunctions
in classDialect
- Parameters:
functionContributions
- The target for the contributions
-
ordinal
public int ordinal()Description copied from interface:FunctionContributor
Determines order in which the contributions will be applied (lowest ordinal first).The range 0-500 is reserved for Hibernate, range 500-1000 for libraries and 1000-Integer.MAX_VALUE for user-defined FunctionContributors.
Contributions from higher precedence contributors (higher numbers) effectively override contributions from lower precedence. E.g. if a contributor with precedence 1000 contributes a function named
"max"
, that will override Hibernate's standard function of that name.- Specified by:
ordinal
in interfaceFunctionContributor
- Overrides:
ordinal
in classDialect
- Returns:
- the ordinal for this FunctionContributor
-
initializeFunctionRegistry
Description copied from class:Dialect
Initialize the given registry with any dialect-specific functions.Support for certain SQL functions is required, and if the database does not support a required function, then the dialect must define a way to emulate it.
These required functions include the functions defined by the JPA query language specification:
-
avg(arg)
- aggregate function -
count([distinct ]arg)
- aggregate function -
max(arg)
- aggregate function -
min(arg)
- aggregate function -
sum(arg)
- aggregate function
-
coalesce(arg0, arg1, ...)
-
nullif(arg0, arg1)
-
lower(arg)
-
upper(arg)
-
length(arg)
-
concat(arg0, arg1, ...)
-
locate(pattern, string[, start])
-
substring(string, start[, length])
-
trim([[spec ][character ]from] string)
-
abs(arg)
-
mod(arg0, arg1)
-
sqrt(arg)
-
current date
-
current time
-
current timestamp
-
any(arg)
- aggregate function -
every(arg)
- aggregate function
-
var_samp(arg)
- aggregate function -
var_pop(arg)
- aggregate function -
stddev_samp(arg)
- aggregate function -
stddev_pop(arg)
- aggregate function
-
cast(arg as Type)
-
extract(field from arg)
-
ln(arg)
-
exp(arg)
-
power(arg0, arg1)
-
floor(arg)
-
ceiling(arg)
-
position(pattern in string)
-
substring(string from start[ for length])
-
overlay(string placing replacement from start[ for length])
java.time
types:-
local date
-
local time
-
local datetime
-
offset datetime
-
instant
-
left(string, length)
-
right(string, length)
-
replace(string, pattern, replacement)
-
pad(string with length spec[ character])
-
repeat(string, times)
-
pi
-
log10(arg)
-
log(base, arg)
-
sign(arg)
-
sin(arg)
-
cos(arg)
-
tan(arg)
-
asin(arg)
-
acos(arg)
-
atan(arg)
-
atan2(arg0, arg1)
-
round(arg0[, arg1])
-
truncate(arg0[, arg1])
-
sinh(arg)
-
tanh(arg)
-
cosh(arg)
-
least(arg0, arg1, ...)
-
greatest(arg0, arg1, ...)
-
degrees(arg)
-
radians(arg)
-
bitand(arg1, arg1)
-
bitor(arg1, arg1)
-
bitxor(arg1, arg1)
-
format(datetime as pattern)
-
collate(string as collation)
-
str(arg)
- synonym ofcast(a as String)
-
ifnull(arg0, arg1)
- synonym ofcoalesce(a, b)
extract()
, and desugared by the parser:-
second(arg)
- synonym ofextract(second from a)
-
minute(arg)
- synonym ofextract(minute from a)
-
hour(arg)
- synonym ofextract(hour from a)
-
day(arg)
- synonym ofextract(day from a)
-
month(arg)
- synonym ofextract(month from a)
-
year(arg)
- synonym ofextract(year from a)
second()
function returns a floating point value, contrary to the integer type returned by the native function with this name on many databases. Thus, we don't just naively map these HQL functions to the native SQL functions with the same names.- Overrides:
initializeFunctionRegistry
in classDialect
-
-
currentDate
Description copied from class:Dialect
Translation of the HQL/JPQLcurrent_date
function, which maps to the Java typeDate
, and of the HQLlocal_date
function which maps to the Java typeLocalDate
.- Overrides:
currentDate
in classDialect
-
currentTime
Description copied from class:Dialect
Translation of the HQL/JPQLcurrent_time
function, which maps to the Java typeTime
which is a time with no time zone. This contradicts ANSI SQL wherecurrent_time
has the typeTIME WITH TIME ZONE
.It is recommended to override this in dialects for databases which support
localtime
ortime at local
.- Overrides:
currentTime
in classDialect
-
currentTimestamp
Description copied from class:Dialect
Translation of the HQL/JPQLcurrent_timestamp
function, which maps to the Java typeTimestamp
which is a datetime with no time zone. This contradicts ANSI SQL wherecurrent_timestamp
has the typeTIMESTAMP WITH TIME ZONE
.It is recommended to override this in dialects for databases which support
localtimestamp
ortimestamp at local
.- Overrides:
currentTimestamp
in classDialect
-
currentLocalTime
Description copied from class:Dialect
Translation of the HQLlocal_time
function, which maps to the Java typeLocalTime
which is a time with no time zone. It should usually be the same SQL function as forDialect.currentTime()
.It is recommended to override this in dialects for databases which support
localtime
orcurrent_time at local
.- Overrides:
currentLocalTime
in classDialect
-
currentLocalTimestamp
Description copied from class:Dialect
Translation of the HQLlocal_datetime
function, which maps to the Java typeLocalDateTime
which is a datetime with no time zone. It should usually be the same SQL function as forDialect.currentTimestamp()
.It is recommended to override this in dialects for databases which support
localtimestamp
orcurrent_timestamp at local
.- Overrides:
currentLocalTimestamp
in classDialect
-
currentTimestampWithTimeZone
Description copied from class:Dialect
Translation of the HQLoffset_datetime
function, which maps to the Java typeOffsetDateTime
which is a datetime with a time zone. This in principle correctly maps to the ANSI SQLcurrent_timestamp
which has the typeTIMESTAMP WITH TIME ZONE
.- Overrides:
currentTimestampWithTimeZone
in classDialect
-
extractPattern
Description copied from class:Dialect
Obtain a pattern for the SQL equivalent to anextract()
function call. The resulting pattern must contain ?1 and ?2 placeholders for the arguments.This method does not need to handle
TemporalUnit.NANOSECOND
,TemporalUnit.NATIVE
,TemporalUnit.OFFSET
,TemporalUnit.DATE
,TemporalUnit.TIME
,TemporalUnit.WEEK_OF_YEAR
, orTemporalUnit.WEEK_OF_MONTH
, which are already desugared byExtractFunction
.- Overrides:
extractPattern
in classDialect
- Parameters:
unit
- the first argument
-
castPattern
Description copied from class:Dialect
Obtain a pattern for the SQL equivalent to acast()
function call. The resulting pattern must contain ?1 and ?2 placeholders for the arguments.- Overrides:
castPattern
in classDialect
- Parameters:
from
- aCastType
indicating the type of the value argumentto
- aCastType
indicating the type the value argument is cast to
-
trimPattern
Description copied from class:Dialect
Obtain a pattern for the SQL equivalent to atrim()
function call. The resulting pattern must contain a ?1 placeholder for the argument of typeString
.- Overrides:
trimPattern
in classDialect
- Parameters:
specification
-leading
ortrailing
character
- the character to trim
-
trimPattern
Description copied from class:Dialect
Obtain a pattern for the SQL equivalent to atrim()
function call. The resulting pattern must contain a ?1 placeholder for the argument of typeString
and a ?2 placeholder for the trim character ifisWhitespace
was false.- Overrides:
trimPattern
in classDialect
- Parameters:
specification
- leading, trailing or bothisWhitespace
-true
if the trim character is a whitespace and can be omitted,false
if it must be explicit and a ?2 placeholder should be included in the pattern
-
supportsFractionalTimestampArithmetic
public boolean supportsFractionalTimestampArithmetic()Description copied from class:Dialect
Whether the database supports adding a fractional interval to a timestamp, for exampletimestamp + 0.5 second
.- Overrides:
supportsFractionalTimestampArithmetic
in classDialect
-
timestampdiffPattern
public String timestampdiffPattern(TemporalUnit unit, TemporalType fromTemporalType, TemporalType toTemporalType) Description copied from class:Dialect
Obtain a pattern for the SQL equivalent to atimestampdiff()
function call. The resulting pattern must contain ?1, ?2, and ?3 placeholders for the arguments.- Overrides:
timestampdiffPattern
in classDialect
- Parameters:
unit
- the first argumentfromTemporalType
- true if the first argument is a timestamp, false if a datetoTemporalType
- true if the second argument is
-
timestampaddPattern
public String timestampaddPattern(TemporalUnit unit, TemporalType temporalType, IntervalType intervalType) Description copied from class:Dialect
Obtain a pattern for the SQL equivalent to atimestampadd()
function call. The resulting pattern must contain ?1, ?2, and ?3 placeholders for the arguments.- Overrides:
timestampaddPattern
in classDialect
- Parameters:
unit
- The unit to add to the temporaltemporalType
- The type of the temporalintervalType
- The type of interval to add or null if it's not a native interval
-
equivalentTypes
public boolean equivalentTypes(int typeCode1, int typeCode2) Description copied from class:Dialect
Do the given JDBC type codes, as defined inTypes
represent essentially the same type in this dialect of SQL?The default implementation treats
NUMERIC
andDECIMAL
as the same type, andFLOAT
,REAL
, andDOUBLE
as essentially the same type, since the ANSI SQL specification fails to meaningfully distinguish them.The default implementation also treats
VARCHAR
,NVARCHAR
,LONGVARCHAR
, andLONGNVARCHAR
as the same type, andBINARY
andLONGVARBINARY
as the same type, since Hibernate doesn't really differentiate these types.On the other hand, integral types are not treated as equivalent, instead,
Dialect.isCompatibleIntegralType(int, int)
is responsible for determining if the types are compatible.- Overrides:
equivalentTypes
in classDialect
- Parameters:
typeCode1
- the first column type infotypeCode2
- the second column type info- Returns:
true
if the two type codes are equivalent
-
getDefaultProperties
Description copied from class:Dialect
Retrieve a set of default Hibernate properties for this database.An implementation may set configuration properties from
Dialect.initDefaultProperties()
, though it is discouraged. the- Overrides:
getDefaultProperties
in classDialect
- Returns:
- the Hibernate configuration properties
- See Also:
-
getDefaultStatementBatchSize
public int getDefaultStatementBatchSize()Description copied from class:Dialect
The default value to use for the configuration property "hibernate.jdbc.batch_size".- Overrides:
getDefaultStatementBatchSize
in classDialect
-
getDefaultNonContextualLobCreation
public boolean getDefaultNonContextualLobCreation()Description copied from class:Dialect
The default value to use for the configuration property "hibernate.jdbc.lob.non_contextual_creation".- Overrides:
getDefaultNonContextualLobCreation
in classDialect
-
getDefaultUseGetGeneratedKeys
public boolean getDefaultUseGetGeneratedKeys()Description copied from class:Dialect
The default value to use for the configuration property "hibernate.jdbc.use_get_generated_keys".- Overrides:
getDefaultUseGetGeneratedKeys
in classDialect
-
toString
-
contribute
Description copied from interface:TypeContributor
Contribute types- Specified by:
contribute
in interfaceTypeContributor
- Overrides:
contribute
in classDialect
- Parameters:
typeContributions
- The callback for adding contributed typesserviceRegistry
- The service registry
-
contributeTypes
Description copied from class:Dialect
A callback which allows theDialect
to contribute types.- Overrides:
contributeTypes
in classDialect
- Parameters:
typeContributions
- Callback to contribute the typesserviceRegistry
- The service registry
-
getLobMergeStrategy
Description copied from class:Dialect
Get theLobMergeStrategy
to use,Dialect.NEW_LOCATOR_LOB_MERGE_STRATEGY
by default.- Overrides:
getLobMergeStrategy
in classDialect
-
getNativeIdentifierGeneratorStrategy
Description copied from class:Dialect
The name identifying the "native" id generation strategy for this dialect.This is the name of the id generation strategy which should be used when
"native"
is specified inhbm.xml
.- Overrides:
getNativeIdentifierGeneratorStrategy
in classDialect
- Returns:
- The name identifying the native generator strategy.
-
getIdentityColumnSupport
Description copied from class:Dialect
Get the appropriateIdentityColumnSupport
for this dialect.- Overrides:
getIdentityColumnSupport
in classDialect
- Returns:
- the IdentityColumnSupport
-
getSequenceSupport
Description copied from class:Dialect
Get the appropriateSequenceSupport
for this dialect.- Overrides:
getSequenceSupport
in classDialect
-
getQuerySequencesString
Description copied from class:Dialect
Get theselect
command used retrieve the names of all sequences.- Overrides:
getQuerySequencesString
in classDialect
- Returns:
- The select command; or null if sequences are not supported.
-
getSequenceInformationExtractor
Description copied from class:Dialect
ASequenceInformationExtractor
which is able to extractSequenceInformation
from the JDBC result set returned whenDialect.getQuerySequencesString()
is executed.- Overrides:
getSequenceInformationExtractor
in classDialect
-
getSelectGUIDString
Description copied from class:Dialect
Get the command used to select a GUID from the database.Optional operation.
- Overrides:
getSelectGUIDString
in classDialect
- Returns:
- The appropriate command.
-
supportsTemporaryTables
public boolean supportsTemporaryTables()Description copied from class:Dialect
Does this database have some sort of support for temporary tables?- Overrides:
supportsTemporaryTables
in classDialect
- Returns:
- true by default, since most do
-
supportsTemporaryTablePrimaryKey
public boolean supportsTemporaryTablePrimaryKey()Description copied from class:Dialect
Does this database support primary keys for temporary tables?- Overrides:
supportsTemporaryTablePrimaryKey
in classDialect
- Returns:
- true by default, since most do
-
getLimitHandler
Description copied from class:Dialect
Obtain aLimitHandler
that implements pagination support forQuery.setMaxResults(int)
andQuery.setFirstResult(int)
.- Overrides:
getLimitHandler
in classDialect
-
supportsLockTimeouts
public boolean supportsLockTimeouts()Description copied from class:Dialect
Does this dialect support specifying timeouts when requesting locks.- Overrides:
supportsLockTimeouts
in classDialect
- Returns:
- True is this dialect supports specifying lock timeouts.
-
isLockTimeoutParameterized
Deprecated, for removal: This API element is subject to removal in a future version.Description copied from class:Dialect
If this dialect supports specifying lock timeouts, are those timeouts rendered into theSQL
string as parameters? The implication is that Hibernate will need to bind the timeout value as a parameter in thePreparedStatement
. If true, the parameter position is always handled as the last parameter; if the dialect specifies the lock timeout elsewhere in theSQL
statement then the timeout value should be directly rendered into the statement and this method should return false.- Overrides:
isLockTimeoutParameterized
in classDialect
- Returns:
- True if the lock timeout is rendered into the
SQL
string as a parameter; false otherwise.
-
getLockingStrategy
Description copied from class:Dialect
ALockingStrategy
which is able to acquire a database-level lock with the specified level.- Overrides:
getLockingStrategy
in classDialect
- Parameters:
lockable
- The persister for the entity to be locked.lockMode
- The type of lock to be acquired.- Returns:
- The appropriate locking strategy.
-
getForUpdateString
Description copied from class:Dialect
Given a set ofLockOptions
(lock level, timeout), determine the appropriatefor update
fragment to use to obtain the lock.- Overrides:
getForUpdateString
in classDialect
- Parameters:
lockOptions
- contains the lock mode to apply.- Returns:
- The appropriate
for update
fragment.
-
getForUpdateString
Description copied from class:Dialect
Given aLockMode
, determine the appropriatefor update
fragment to use to obtain the lock.- Overrides:
getForUpdateString
in classDialect
- Parameters:
lockMode
- The lock mode to apply.- Returns:
- The appropriate for update fragment.
-
getForUpdateString
Description copied from class:Dialect
Get the string to append toSELECT
statements to acquire pessimistic UPGRADE locks for this dialect.- Overrides:
getForUpdateString
in classDialect
- Returns:
- The appropriate
FOR UPDATE
clause string.
-
getWriteLockString
Description copied from class:Dialect
Get the string to append toSELECT
statements to acquire pessimistic WRITE locks for this dialect.Location of the returned string is treated the same as
Dialect.getForUpdateString()
.- Overrides:
getWriteLockString
in classDialect
- Parameters:
timeout
- in milliseconds, -1 for indefinite wait and 0 for no wait.- Returns:
- The appropriate
LOCK
clause string.
-
getWriteLockString
Description copied from class:Dialect
Get the string to append toSELECT
statements to acquire WRITE locks for this dialect, given the aliases of the columns to be write locked.Location of the returned string is treated the same as
Dialect.getForUpdateString()
.- Overrides:
getWriteLockString
in classDialect
- Parameters:
aliases
- The columns to be read locked.timeout
- in milliseconds, -1 for indefinite wait and 0 for no wait.- Returns:
- The appropriate
LOCK
clause string.
-
getReadLockString
Description copied from class:Dialect
Get the string to append toSELECT
statements to acquire READ locks for this dialect.Location of the returned string is treated the same as
Dialect.getForUpdateString()
.- Overrides:
getReadLockString
in classDialect
- Parameters:
timeout
- in milliseconds, -1 for indefinite wait and 0 for no wait.- Returns:
- The appropriate
LOCK
clause string.
-
getReadLockString
Description copied from class:Dialect
Get the string to append toSELECT
statements to acquire READ locks for this dialect, given the aliases of the columns to be read locked.Location of the returned string is treated the same as
Dialect.getForUpdateString()
.- Overrides:
getReadLockString
in classDialect
- Parameters:
aliases
- The columns to be read locked.timeout
- in milliseconds, -1 for indefinite wait and 0 for no wait.- Returns:
- The appropriate
LOCK
clause string.
-
getWriteRowLockStrategy
Description copied from class:Dialect
The row lock strategy to use for write locks.- Overrides:
getWriteRowLockStrategy
in classDialect
-
getReadRowLockStrategy
Description copied from class:Dialect
The row lock strategy to use for read locks.- Overrides:
getReadRowLockStrategy
in classDialect
-
supportsOuterJoinForUpdate
public boolean supportsOuterJoinForUpdate()Description copied from class:Dialect
Does this dialect supportFOR UPDATE
in conjunction with outer-joined rows?- Overrides:
supportsOuterJoinForUpdate
in classDialect
- Returns:
- True if outer-joined rows can be locked via
FOR UPDATE
.
-
getForUpdateString
Description copied from class:Dialect
Get theFOR UPDATE OF column_list
fragment appropriate for this dialect, given the aliases of the columns to be write locked.- Overrides:
getForUpdateString
in classDialect
- Parameters:
aliases
- The columns to be write locked.- Returns:
- The appropriate
FOR UPDATE OF column_list
clause string.
-
getForUpdateString
Description copied from class:Dialect
Get theFOR UPDATE OF
orFOR SHARE OF
fragment appropriate for this dialect, given the aliases of the columns to be locked.- Overrides:
getForUpdateString
in classDialect
- Parameters:
aliases
- The columns to be locked.lockOptions
- the lock options to apply- Returns:
- The appropriate
FOR UPDATE OF column_list
clause string.
-
getForUpdateNowaitString
Description copied from class:Dialect
Retrieves theFOR UPDATE NOWAIT
syntax specific to this dialect.- Overrides:
getForUpdateNowaitString
in classDialect
- Returns:
- The appropriate
FOR UPDATE NOWAIT
clause string.
-
getForUpdateSkipLockedString
Description copied from class:Dialect
Retrieves theFOR UPDATE SKIP LOCKED
syntax specific to this dialect.- Overrides:
getForUpdateSkipLockedString
in classDialect
- Returns:
- The appropriate
FOR UPDATE SKIP LOCKED
clause string.
-
getForUpdateNowaitString
Description copied from class:Dialect
Get theFOR UPDATE OF column_list NOWAIT
fragment appropriate for this dialect, given the aliases of the columns to be write locked.- Overrides:
getForUpdateNowaitString
in classDialect
- Parameters:
aliases
- The columns to be write locked.- Returns:
- The appropriate
FOR UPDATE OF colunm_list NOWAIT
clause string.
-
getForUpdateSkipLockedString
Description copied from class:Dialect
Get theFOR UPDATE OF column_list SKIP LOCKED
fragment appropriate for this dialect, given the aliases of the columns to be write locked.- Overrides:
getForUpdateSkipLockedString
in classDialect
- Parameters:
aliases
- The columns to be write locked.- Returns:
- The appropriate
FOR UPDATE colunm_list SKIP LOCKED
clause string.
-
appendLockHint
Description copied from class:Dialect
Some dialects support an alternative means toSELECT FOR UPDATE
, whereby a "lock hint" is appended to the table name in thefrom
clause.- Overrides:
appendLockHint
in classDialect
- Parameters:
lockOptions
- The lock options to applytableName
- The name of the table to which to apply the lock hint.- Returns:
- The table with any required lock hints.
-
applyLocksToSql
public String applyLocksToSql(String sql, LockOptions aliasedLockOptions, Map<String, String[]> keyColumnNames) Description copied from class:Dialect
Modifies the given SQL, applying the appropriate updates for the specified lock modes and key columns.This allows emulation of
SELECT FOR UPDATE
for dialects which do not support the standard syntax.- Overrides:
applyLocksToSql
in classDialect
- Parameters:
sql
- the SQL string to modifyaliasedLockOptions
- lock options indexed by aliased table names.keyColumnNames
- a map of key columns indexed by aliased table names.- Returns:
- the modified SQL string.
-
getCreateTableString
Description copied from class:Dialect
The command used to create a table, usuallycreate table
.- Overrides:
getCreateTableString
in classDialect
- Returns:
- The command used to create a table.
-
getTableTypeString
Description copied from class:Dialect
An arbitrary fragment appended to the end of thecreate table
statement.- Overrides:
getTableTypeString
in classDialect
-
supportsIfExistsBeforeTableName
public boolean supportsIfExistsBeforeTableName()Description copied from class:Dialect
For dropping a table, can the phraseif exists
be applied before the table name?- Overrides:
supportsIfExistsBeforeTableName
in classDialect
- Returns:
true
ifif exists
can be applied before the table name
-
supportsIfExistsAfterTableName
public boolean supportsIfExistsAfterTableName()Description copied from class:Dialect
For dropping a table, can the phraseif exists
be applied after the table name?- Overrides:
supportsIfExistsAfterTableName
in classDialect
- Returns:
true
ifif exists
can be applied after the table name
-
getDropTableString
Description copied from class:Dialect
The command used to drop a table with the given name, usuallydrop table tab_name
.- Overrides:
getDropTableString
in classDialect
- Parameters:
tableName
- The name of the table to drop- Returns:
- The
drop table
statement as a string - See Also:
-
getCreateIndexString
Description copied from class:Dialect
The command used to create an index, usuallycreate index
orcreate unique index
.- Overrides:
getCreateIndexString
in classDialect
- Parameters:
unique
-true
if the index is a unique index- Returns:
- The command used to create an index.
-
getCreateIndexTail
Description copied from class:Dialect
A string to be appended to the end of thecreate index
command, usually to specify thatnull
values are to be considered distinct.- Overrides:
getCreateIndexTail
in classDialect
-
qualifyIndexName
public boolean qualifyIndexName()Description copied from class:Dialect
Do we need to qualify index names with the schema name?- Overrides:
qualifyIndexName
in classDialect
- Returns:
true
if we do
-
getCreateMultisetTableString
Description copied from class:Dialect
Slight variation onDialect.getCreateTableString()
. Here, we have the command used to create a table when there is no primary key and duplicate rows are expected.- Overrides:
getCreateMultisetTableString
in classDialect
- Returns:
- The command used to create a multiset table.
-
hasAlterTable
public boolean hasAlterTable()Description copied from class:Dialect
Does this dialect support theALTER TABLE
syntax?- Overrides:
hasAlterTable
in classDialect
- Returns:
- True if we support altering existing tables; false otherwise.
-
getAlterTableString
Description copied from class:Dialect
The command used to alter a table with the given name, usuallyalter table tab_name
oralter table tab_name if exists
.We prefer the
if exists
form if supported.- Overrides:
getAlterTableString
in classDialect
- Parameters:
tableName
- The name of the table to alter- Returns:
- The command used to alter a table.
-
supportsIfExistsAfterAlterTable
public boolean supportsIfExistsAfterAlterTable()Description copied from class:Dialect
For analter table
, can the phraseif exists
be applied?- Overrides:
supportsIfExistsAfterAlterTable
in classDialect
- Returns:
true
ifif exists
can be applied afteralter table
-
getAddColumnString
Description copied from class:Dialect
The subcommand of thealter table
command used to add a column to a table, usuallyadd column
oradd
.- Overrides:
getAddColumnString
in classDialect
- Returns:
- The
add column
fragment.
-
getAddColumnSuffixString
Description copied from class:Dialect
The syntax for the suffix used to add a column to a table.- Overrides:
getAddColumnSuffixString
in classDialect
- Returns:
- The suffix of the
add column
fragment.
-
dropConstraints
public boolean dropConstraints()Description copied from class:Dialect
Do we need to drop constraints before dropping tables in this dialect?- Overrides:
dropConstraints
in classDialect
- Returns:
- True if constraints must be dropped prior to dropping the table; false otherwise.
-
getDropForeignKeyString
Description copied from class:Dialect
The subcommand of thealter table
command used to drop a foreign key constraint, usuallydrop constraint
.- Overrides:
getDropForeignKeyString
in classDialect
-
getDropUniqueKeyString
Description copied from class:Dialect
The subcommand of thealter table
command used to drop a unique key constraint.- Overrides:
getDropUniqueKeyString
in classDialect
-
supportsIfExistsBeforeConstraintName
public boolean supportsIfExistsBeforeConstraintName()Description copied from class:Dialect
For dropping a constraint with analter table
statement, can the phraseif exists
be applied before the constraint name?- Overrides:
supportsIfExistsBeforeConstraintName
in classDialect
- Returns:
true
ifif exists
can be applied before the constraint name
-
supportsIfExistsAfterConstraintName
public boolean supportsIfExistsAfterConstraintName()Description copied from class:Dialect
For dropping a constraint with analter table
, can the phraseif exists
be applied after the constraint name?- Overrides:
supportsIfExistsAfterConstraintName
in classDialect
- Returns:
true
ifif exists
can be applied after the constraint name
-
supportsAlterColumnType
public boolean supportsAlterColumnType()Description copied from class:Dialect
Does this dialect support modifying the type of an existing column?- Overrides:
supportsAlterColumnType
in classDialect
-
getAlterColumnTypeString
public String getAlterColumnTypeString(String columnName, String columnType, String columnDefinition) Description copied from class:Dialect
The fragment of analter table
command which modifies a column type, or null if column types cannot be modified. Oftenalter column col_name set data type col_type
.- Overrides:
getAlterColumnTypeString
in classDialect
- Parameters:
columnName
- the name of the columncolumnType
- the new type of the columncolumnDefinition
- the full column definition- Returns:
- a fragment to be appended to
alter table
-
getAddForeignKeyConstraintString
public String getAddForeignKeyConstraintString(String constraintName, String[] foreignKey, String referencedTable, String[] primaryKey, boolean referencesPrimaryKey) Description copied from class:Dialect
The syntax used to add a foreign key constraint to a table, with the referenced key columns explicitly specified.- Overrides:
getAddForeignKeyConstraintString
in classDialect
- Parameters:
constraintName
- The foreign key constraint nameforeignKey
- The names of the columns comprising the foreign keyreferencedTable
- The table referenced by the foreign keyprimaryKey
- The explicit columns in the referencedTable referenced by this foreign key.referencesPrimaryKey
- if false, constraint should be explicit about which column names the constraint refers to- Returns:
- the "add FK" fragment
-
getAddForeignKeyConstraintString
Description copied from class:Dialect
The syntax used to add a foreign key constraint to a table, given the definition of the foreign key as a string.- Overrides:
getAddForeignKeyConstraintString
in classDialect
- Parameters:
constraintName
- The foreign key constraint nameforeignKeyDefinition
- The whole definition of the foreign key as a fragment
-
getAddPrimaryKeyConstraintString
Description copied from class:Dialect
The syntax used to add a primary key constraint to a table.- Overrides:
getAddPrimaryKeyConstraintString
in classDialect
- Parameters:
constraintName
- The name of the PK constraint.- Returns:
- The "add PK" fragment
-
getFallbackSqmMutationStrategy
public SqmMultiTableMutationStrategy getFallbackSqmMutationStrategy(EntityMappingType entityDescriptor, RuntimeModelCreationContext runtimeModelCreationContext) Description copied from class:Dialect
TheSqmMultiTableMutationStrategy
to use when not specified byQueryEngineOptions.getCustomSqmMultiTableMutationStrategy()
. -
getFallbackSqmInsertStrategy
public SqmMultiTableInsertStrategy getFallbackSqmInsertStrategy(EntityMappingType entityDescriptor, RuntimeModelCreationContext runtimeModelCreationContext) Description copied from class:Dialect
TheSqmMultiTableInsertStrategy
to use when not specified byQueryEngineOptions.getCustomSqmMultiTableInsertStrategy()
. -
getCreateUserDefinedTypeKindString
Description copied from class:Dialect
The kind of user-defined type to create, or the empty string if this does not need to be specified. Included aftercreate type type_name as
, but before the list of members.- Overrides:
getCreateUserDefinedTypeKindString
in classDialect
-
getCreateUserDefinedTypeExtensionsString
Description copied from class:Dialect
An arbitrary extension to append to the end of the UDTcreate type
command.- Overrides:
getCreateUserDefinedTypeExtensionsString
in classDialect
-
supportsIfExistsBeforeTypeName
public boolean supportsIfExistsBeforeTypeName()Description copied from class:Dialect
For dropping a type, can the phraseif exists
be applied before the type name?- Overrides:
supportsIfExistsBeforeTypeName
in classDialect
- Returns:
true
ifif exists
can be applied before the type name
-
supportsIfExistsAfterTypeName
public boolean supportsIfExistsAfterTypeName()Description copied from class:Dialect
For dropping a type, can the phraseif exists
be applied after the type name?- Overrides:
supportsIfExistsAfterTypeName
in classDialect
- Returns:
true
ifif exists
can be applied after the type name
-
registerResultSetOutParameter
public int registerResultSetOutParameter(CallableStatement statement, int position) throws SQLException Description copied from class:Dialect
Registers a parameter capable of returning aResultSet
by position, either anOUT
parameter, or aREF_CURSOR
parameter as defined in Java 8.- Overrides:
registerResultSetOutParameter
in classDialect
- Parameters:
statement
- The callable statement.position
- The bind position at which to register the output param.- Returns:
- The number of (contiguous) bind positions used.
- Throws:
SQLException
- Indicates problems registering the param.
-
registerResultSetOutParameter
public int registerResultSetOutParameter(CallableStatement statement, String name) throws SQLException Description copied from class:Dialect
Registers a parameter capable of returning aResultSet
by name, either anOUT
parameter, or aREF_CURSOR
parameter as defined in Java 8.- Overrides:
registerResultSetOutParameter
in classDialect
- Parameters:
statement
- The callable statement.name
- The parameter name (for drivers which support named parameters).- Returns:
- The number of (contiguous) bind positions used.
- Throws:
SQLException
- Indicates problems registering the param.
-
getResultSet
Description copied from class:Dialect
Given a callable statement previously processed byDialect.registerResultSetOutParameter(java.sql.CallableStatement, int)
, extract theResultSet
from theOUT
parameter.- Overrides:
getResultSet
in classDialect
- Parameters:
statement
- The callable statement.- Returns:
- The extracted result set.
- Throws:
SQLException
- Indicates problems extracting the result set.
-
getResultSet
Description copied from class:Dialect
Given a callable statement previously processed byDialect.registerResultSetOutParameter(java.sql.CallableStatement, int)
, extract theResultSet
from the positionalOUT
parameter.- Overrides:
getResultSet
in classDialect
- Parameters:
statement
- The callable statement.position
- The bind position at which to register the output param.- Returns:
- The extracted result set.
- Throws:
SQLException
- Indicates problems extracting the result set.
-
getResultSet
Description copied from class:Dialect
Given a callable statement previously processed byDialect.registerResultSetOutParameter(java.sql.CallableStatement, int)
, extract theResultSet
from the namedOUT
parameter.- Overrides:
getResultSet
in classDialect
- Parameters:
statement
- The callable statement.name
- The parameter name (for drivers which support named parameters).- Returns:
- The extracted result set.
- Throws:
SQLException
- Indicates problems extracting the result set.
-
supportsCurrentTimestampSelection
public boolean supportsCurrentTimestampSelection()Description copied from class:Dialect
Does this dialect support some way to retrieve the current timestamp value from the database?- Overrides:
supportsCurrentTimestampSelection
in classDialect
- Returns:
- True if the current timestamp can be retrieved; false otherwise.
-
isCurrentTimestampSelectStringCallable
public boolean isCurrentTimestampSelectStringCallable()Description copied from class:Dialect
Is the command returned byDialect.getCurrentTimestampSelectString()
treated as callable?Typically, this indicates the use of the JDBC escape syntax.
- Overrides:
isCurrentTimestampSelectStringCallable
in classDialect
- Returns:
- if the
Dialect.getCurrentTimestampSelectString()
is treated as callable; false otherwise.
-
getCurrentTimestampSelectString
Description copied from class:Dialect
The command used to retrieve the current timestamp from the database.- Overrides:
getCurrentTimestampSelectString
in classDialect
-
supportsStandardCurrentTimestampFunction
public boolean supportsStandardCurrentTimestampFunction()Description copied from class:Dialect
Does this dialect have an ANSI SQLcurrent_timestamp
function?- Overrides:
supportsStandardCurrentTimestampFunction
in classDialect
-
buildSQLExceptionConversionDelegate
Description copied from class:Dialect
An instance ofSQLExceptionConversionDelegate
for interpreting dialect-specific error or SQLState codes.If this method is overridden to return a non-null value, the default
SQLExceptionConverter
will use the returnedSQLExceptionConversionDelegate
in addition to the following standard delegates:- a "static" delegate based on the JDBC4-defined
SQLException
hierarchy, and - a delegate that interprets SQLState codes as either X/Open or SQL-2003 codes, depending on what is reported by the JDBC driver.
It is strongly recommended that every
Dialect
implementation override this method, since interpretation of a SQL error is much more accurate when based on the vendor-specific error code, rather than on the SQLState.- Overrides:
buildSQLExceptionConversionDelegate
in classDialect
- Returns:
- The
SQLExceptionConversionDelegate
for this dialect
- a "static" delegate based on the JDBC4-defined
-
getViolatedConstraintNameExtractor
Description copied from class:Dialect
AViolatedConstraintNameExtractor
for extracting the name of a violated constraint from aSQLException
.- Specified by:
getViolatedConstraintNameExtractor
in interfaceConversionContext
- Overrides:
getViolatedConstraintNameExtractor
in classDialect
-
getSelectClauseNullString
Description copied from class:Dialect
Given a JDBC type code, return the expression for a literal null value of that type, to use in aselect
clause.The
select
query will be an element of aUNION
orUNION ALL
.- Overrides:
getSelectClauseNullString
in classDialect
- Parameters:
sqlType
- TheTypes
type code.typeConfiguration
- The type configuration- Returns:
- The appropriate select clause value fragment.
-
supportsUnionAll
public boolean supportsUnionAll()Description copied from class:Dialect
Does this dialect supportUNION ALL
?- Overrides:
supportsUnionAll
in classDialect
- Returns:
- True if
UNION ALL
is supported; false otherwise.
-
supportsUnionInSubquery
public boolean supportsUnionInSubquery()Description copied from class:Dialect
Does this dialect supportUNION
in a subquery.- Overrides:
supportsUnionInSubquery
in classDialect
- Returns:
- True if
UNION
is supported in a subquery; false otherwise.
-
getNoColumnsInsertString
Deprecated.Description copied from class:Dialect
The fragment used to insert a row without specifying any column values, usually just()
, but sometimesdefault values
.- Overrides:
getNoColumnsInsertString
in classDialect
- Returns:
- The appropriate empty values clause.
-
supportsNoColumnsInsert
public boolean supportsNoColumnsInsert()Description copied from class:Dialect
Is theINSERT
statement is allowed to contain no columns?- Overrides:
supportsNoColumnsInsert
in classDialect
- Returns:
- if this dialect supports no-column
INSERT
.
-
getLowercaseFunction
Description copied from class:Dialect
The name of the SQL function that transforms a string to lowercase, almost alwayslower
.- Overrides:
getLowercaseFunction
in classDialect
- Returns:
- The dialect-specific lowercase function.
-
getCaseInsensitiveLike
Description copied from class:Dialect
The name of the SQL operator that performs case-insensitiveLIKE
comparisons.- Overrides:
getCaseInsensitiveLike
in classDialect
- Returns:
- The dialect-specific case-insensitive like operator.
-
supportsCaseInsensitiveLike
public boolean supportsCaseInsensitiveLike()Description copied from class:Dialect
Does this dialect support case-insensitiveLIKE
comparisons?- Overrides:
supportsCaseInsensitiveLike
in classDialect
- Returns:
true
if the database supports case-insensitive like comparisons,false
otherwise. The default isfalse
.
-
supportsTruncateWithCast
public boolean supportsTruncateWithCast()Description copied from class:Dialect
Does this dialect support truncation of values to a specified length via acast
?- Overrides:
supportsTruncateWithCast
in classDialect
- Returns:
true
if the database supports truncation via a cast,false
otherwise. The default istrue
.
-
transformSelectString
Description copied from class:Dialect
Meant as a means for end users to affect the select strings being sent to the database and perhaps manipulate them in some fashion.- Overrides:
transformSelectString
in classDialect
- Parameters:
select
- The select command- Returns:
- The mutated select command, or the same as was passed in.
-
getMaxAliasLength
public int getMaxAliasLength()Description copied from class:Dialect
What is the maximum length Hibernate can use for generated aliases?- Overrides:
getMaxAliasLength
in classDialect
- Returns:
- The maximum length.
-
getMaxIdentifierLength
public int getMaxIdentifierLength()Description copied from class:Dialect
What is the maximum identifier length supported by this dialect?- Overrides:
getMaxIdentifierLength
in classDialect
- Returns:
- The maximum length.
-
toBooleanValueString
Description copied from class:Dialect
The SQL literal expression representing the given boolean value.- Overrides:
toBooleanValueString
in classDialect
- Parameters:
bool
- The boolean value- Returns:
- The appropriate SQL literal.
-
appendBooleanValueString
Description copied from class:Dialect
Append the SQL literal expression representing the given boolean value to the givenSqlAppender
.- Overrides:
appendBooleanValueString
in classDialect
- Parameters:
appender
- TheSqlAppender
to append the literal expression tobool
- The boolean value
-
registerKeyword
Description copied from class:Dialect
Register a keyword.- Overrides:
registerKeyword
in classDialect
- Parameters:
word
- a reserved word in this SQL dialect
-
getKeywords
Description copied from class:Dialect
The keywords of this SQL dialect.- Overrides:
getKeywords
in classDialect
-
buildIdentifierHelper
public IdentifierHelper buildIdentifierHelper(IdentifierHelperBuilder builder, DatabaseMetaData dbMetaData) throws SQLException Description copied from class:Dialect
TheIdentifierHelper
indicated by this dialect for handling identifier conversions. Returningnull
is allowed and indicates that Hibernate should fall back to building a "standard" helper. In the fallback path, any changes made to the IdentifierHelperBuilder during this call will still be incorporated into the built IdentifierHelper.The incoming builder will have the following set:
IdentifierHelperBuilder.isGloballyQuoteIdentifiers()
IdentifierHelperBuilder.getUnquotedCaseStrategy()
- initialized to UPPERIdentifierHelperBuilder.getQuotedCaseStrategy()
- initialized to MIXED
By default, Hibernate will do the following:
- Call
IdentifierHelperBuilder.applyIdentifierCasing(DatabaseMetaData)
- Call
IdentifierHelperBuilder.applyReservedWords(DatabaseMetaData)
- Applies
AnsiSqlKeywords.sql2003()
as reserved words - Applies the {#link #sqlKeywords} collected here as reserved words
- Applies the Dialect's
NameQualifierSupport
, if it defines one
- Overrides:
buildIdentifierHelper
in classDialect
- Parameters:
builder
- A partially-configuredIdentifierHelperBuilder
.dbMetaData
- Access to the metadata returned from the driver if needed and if available. WARNING: it may benull
.- Returns:
- The
IdentifierHelper
instance to use, ornull
to indicate Hibernate should use its fallback path - Throws:
SQLException
- Accessing theDatabaseMetaData
can throw it. Just rethrow and Hibernate will handle it.- See Also:
-
openQuote
public char openQuote()Description copied from class:Dialect
The character specific to this dialect used to begin a quoted identifier. -
closeQuote
public char closeQuote()Description copied from class:Dialect
The character specific to this dialect used to close a quoted identifier.- Overrides:
closeQuote
in classDialect
- Returns:
- The dialect-specific close quote character.
-
toQuotedIdentifier
Description copied from class:Dialect
Apply dialect-specific quoting.- Overrides:
toQuotedIdentifier
in classDialect
- Parameters:
name
- The value to be quoted.- Returns:
- The quoted value.
- See Also:
-
quote
Description copied from class:Dialect
Apply dialect-specific quoting if the given name is quoted using backticks.By default, the incoming name is checked to see if its first character is a backtick (
`
). If it is, the dialect specific quoting is applied. -
getFallbackSchemaManagementTool
@Incubating public SchemaManagementTool getFallbackSchemaManagementTool(Map<String, Object> configurationValues, ServiceRegistryImplementor registry) Description copied from class:Dialect
TheSchemaManagementTool
to use if none is explicitly specified.- Overrides:
getFallbackSchemaManagementTool
in classDialect
- Returns:
- a
HibernateSchemaManagementTool
by default
-
getTableExporter
Description copied from class:Dialect
- Overrides:
getTableExporter
in classDialect
-
getTableMigrator
Description copied from class:Dialect
Get aTableMigrator
, usuallyStandardTableMigrator
.- Overrides:
getTableMigrator
in classDialect
-
getTableCleaner
Description copied from class:Dialect
Get a schemaCleaner
, usuallyStandardTableCleaner
.- Overrides:
getTableCleaner
in classDialect
-
getUserDefinedTypeExporter
Description copied from class:Dialect
- Overrides:
getUserDefinedTypeExporter
in classDialect
-
getSequenceExporter
Description copied from class:Dialect
- Overrides:
getSequenceExporter
in classDialect
-
getIndexExporter
Description copied from class:Dialect
- Overrides:
getIndexExporter
in classDialect
-
getForeignKeyExporter
Description copied from class:Dialect
- Overrides:
getForeignKeyExporter
in classDialect
-
getUniqueKeyExporter
Description copied from class:Dialect
- Overrides:
getUniqueKeyExporter
in classDialect
-
getAuxiliaryDatabaseObjectExporter
Description copied from class:Dialect
- Overrides:
getAuxiliaryDatabaseObjectExporter
in classDialect
-
getTemporaryTableExporter
Description copied from class:Dialect
Get aTemporaryTableExporter
, usuallyStandardTemporaryTableExporter
.- Overrides:
getTemporaryTableExporter
in classDialect
-
getSupportedTemporaryTableKind
Description copied from class:Dialect
The kind of temporary tables that are supported on this database.- Overrides:
getSupportedTemporaryTableKind
in classDialect
-
getTemporaryTableCreateOptions
Description copied from class:Dialect
An arbitrary SQL fragment appended to the end of the statement to create a temporary table, specifying dialect-specific options, ornull
if there are no options to specify.- Overrides:
getTemporaryTableCreateOptions
in classDialect
-
getTemporaryTableCreateCommand
Description copied from class:Dialect
The command to create a temporary table.- Overrides:
getTemporaryTableCreateCommand
in classDialect
-
getTemporaryTableDropCommand
Description copied from class:Dialect
The command to drop a temporary table.- Overrides:
getTemporaryTableDropCommand
in classDialect
-
getTemporaryTableTruncateCommand
Description copied from class:Dialect
The command to truncate a temporary table.- Overrides:
getTemporaryTableTruncateCommand
in classDialect
-
getCreateTemporaryTableColumnAnnotation
Description copied from class:Dialect
Annotation to be appended to the end of each COLUMN clause for temporary tables.- Overrides:
getCreateTemporaryTableColumnAnnotation
in classDialect
- Parameters:
sqlTypeCode
- The SQL type code- Returns:
- The annotation to be appended, for example,
COLLATE DATABASE_DEFAULT
in SQL Server
-
getTemporaryTableDdlTransactionHandling
Description copied from class:Dialect
The sort of transaction handling to use when creating or dropping temporary tables.- Overrides:
getTemporaryTableDdlTransactionHandling
in classDialect
-
getTemporaryTableAfterUseAction
Description copied from class:Dialect
The action to take after finishing use of a temporary table.- Overrides:
getTemporaryTableAfterUseAction
in classDialect
-
getTemporaryTableBeforeUseAction
Description copied from class:Dialect
The action to take before beginning use of a temporary table.- Overrides:
getTemporaryTableBeforeUseAction
in classDialect
-
canCreateCatalog
public boolean canCreateCatalog()Description copied from class:Dialect
Does this dialect support creating and dropping catalogs?- Overrides:
canCreateCatalog
in classDialect
- Returns:
- True if the dialect supports catalog creation; false otherwise.
-
getCreateCatalogCommand
Description copied from class:Dialect
Get the SQL command used to create the named catalog.- Overrides:
getCreateCatalogCommand
in classDialect
- Parameters:
catalogName
- The name of the catalog to be created.- Returns:
- The creation commands
-
getDropCatalogCommand
Description copied from class:Dialect
Get the SQL command used to drop the named catalog.- Overrides:
getDropCatalogCommand
in classDialect
- Parameters:
catalogName
- The name of the catalog to be dropped.- Returns:
- The drop commands
-
canCreateSchema
public boolean canCreateSchema()Description copied from class:Dialect
Does this dialect support creating and dropping schema?- Overrides:
canCreateSchema
in classDialect
- Returns:
- True if the dialect supports schema creation; false otherwise.
-
getCreateSchemaCommand
Description copied from class:Dialect
Get the SQL command used to create the named schema.- Overrides:
getCreateSchemaCommand
in classDialect
- Parameters:
schemaName
- The name of the schema to be created.- Returns:
- The creation commands
-
getDropSchemaCommand
Description copied from class:Dialect
Get the SQL command used to drop the named schema.- Overrides:
getDropSchemaCommand
in classDialect
- Parameters:
schemaName
- The name of the schema to be dropped.- Returns:
- The drop commands
-
getCurrentSchemaCommand
Description copied from class:Dialect
Get the SQL command used to retrieve the current schema name.Works in conjunction with
Dialect.getSchemaNameResolver()
, unless the resultingSchemaNameResolver
does not need this information. For example, a custom implementation might make use of the Java 1.7Connection.getSchema()
method.- Overrides:
getCurrentSchemaCommand
in classDialect
- Returns:
- The current schema retrieval SQL
-
getSchemaNameResolver
Description copied from class:Dialect
Get the strategy for determining the schema name from a JDBCConnection
, usuallyDefaultSchemaNameResolver
.- Overrides:
getSchemaNameResolver
in classDialect
- Returns:
- The schema name resolver strategy
-
hasSelfReferentialForeignKeyBug
public boolean hasSelfReferentialForeignKeyBug()Description copied from class:Dialect
Does the database/driver have bug in deleting rows that refer to other rows being deleted in the same query?- Overrides:
hasSelfReferentialForeignKeyBug
in classDialect
- Returns:
true
if the database/driver has this bug
-
getNullColumnString
Description copied from class:Dialect
The keyword used to specify a nullable column, usually""
, but sometimes" null"
.- Overrides:
getNullColumnString
in classDialect
-
getNullColumnString
Description copied from class:Dialect
The keyword used to specify a nullable column of the given SQL type.- Overrides:
getNullColumnString
in classDialect
-
supportsCommentOn
public boolean supportsCommentOn()Description copied from class:Dialect
Does this dialect support commenting on tables and columns?- Overrides:
supportsCommentOn
in classDialect
- Returns:
true
if commenting is supported
-
getTableComment
Description copied from class:Dialect
Get the comment into a form supported for table definition.- Overrides:
getTableComment
in classDialect
- Parameters:
comment
- The comment to apply- Returns:
- The comment fragment
-
getUserDefinedTypeComment
Description copied from class:Dialect
Get the comment into a form supported for UDT definition.- Overrides:
getUserDefinedTypeComment
in classDialect
- Parameters:
comment
- The comment to apply- Returns:
- The comment fragment
-
getColumnComment
Description copied from class:Dialect
Get the comment into a form supported for column definition.- Overrides:
getColumnComment
in classDialect
- Parameters:
comment
- The comment to apply- Returns:
- The comment fragment
-
supportsColumnCheck
public boolean supportsColumnCheck()Description copied from class:Dialect
Does this dialect support column-level check constraints?- Overrides:
supportsColumnCheck
in classDialect
- Returns:
- True if column-level
check
constraints are supported; false otherwise.
-
supportsTableCheck
public boolean supportsTableCheck()Description copied from class:Dialect
Does this dialect support table-level check constraints?- Overrides:
supportsTableCheck
in classDialect
- Returns:
- True if table-level
check
constraints are supported; false otherwise.
-
supportsCascadeDelete
public boolean supportsCascadeDelete()Description copied from class:Dialect
Does this dialect supporton delete
actions in foreign key definitions?- Overrides:
supportsCascadeDelete
in classDialect
- Returns:
true
if the dialect does support theon delete
clause.
-
getCascadeConstraintsString
Description copied from class:Dialect
The keyword that specifies that adrop table
operation should be cascaded to its constraints, typically" cascade"
where the leading space is required, or the empty string if there is no such keyword in this dialect.- Overrides:
getCascadeConstraintsString
in classDialect
- Returns:
- The cascade drop keyword, if any, with a leading space
-
getColumnAliasExtractor
Description copied from class:Dialect
AColumnAliasExtractor
, usually justResultSetMetaData.getColumnLabel(int)
.- Overrides:
getColumnAliasExtractor
in classDialect
-
useInputStreamToInsertBlob
public boolean useInputStreamToInsertBlob()Description copied from class:Dialect
Should LOBs (both BLOB and CLOB) be bound using stream operations, that is, usingPreparedStatement.setBinaryStream(int, java.io.InputStream, int)
).- Overrides:
useInputStreamToInsertBlob
in classDialect
- Returns:
- True if BLOBs and CLOBs should be bound using stream operations.
-
useConnectionToCreateLob
public boolean useConnectionToCreateLob()Description copied from class:Dialect
Should BLOB, CLOB, and NCLOB be created solely using respectivelyConnection.createBlob()
,Connection.createClob()
, andConnection.createNClob()
.- Overrides:
useConnectionToCreateLob
in classDialect
- Returns:
- True if BLOB, CLOB, and NCLOB should be created using JDBC
Connection
.
-
supportsParametersInInsertSelect
Deprecated, for removal: This API element is subject to removal in a future version.Description copied from class:Dialect
Does this dialect support parameters within theSELECT
clause ofINSERT ... SELECT ...
statements?- Overrides:
supportsParametersInInsertSelect
in classDialect
- Returns:
- True if this is supported; false otherwise.
-
supportsOrdinalSelectItemReference
public boolean supportsOrdinalSelectItemReference()Description copied from class:Dialect
Does this dialect support references to result variables (i.e, select items) by column positions (1-origin) as defined by the select clause?- Overrides:
supportsOrdinalSelectItemReference
in classDialect
- Returns:
- true if result variable references by column positions are supported; false otherwise.
-
getNullOrdering
Description copied from class:Dialect
Returns the default ordering of null.- Overrides:
getNullOrdering
in classDialect
-
supportsNullPrecedence
public boolean supportsNullPrecedence()Description copied from class:Dialect
Does this dialect supportnulls first
andnulls last
?- Overrides:
supportsNullPrecedence
in classDialect
-
isAnsiNullOn
Deprecated.Description copied from class:Dialect
A setting specific toSybaseASEDialect
.- Overrides:
isAnsiNullOn
in classDialect
-
requiresCastForConcatenatingNonStrings
public boolean requiresCastForConcatenatingNonStrings()Description copied from class:Dialect
Does this dialect/database require casting of non-string arguments in theconcat()
function?- Overrides:
requiresCastForConcatenatingNonStrings
in classDialect
- Returns:
true
if casting usingcast()
is required
-
requiresFloatCastingOfIntegerDivision
public boolean requiresFloatCastingOfIntegerDivision()Description copied from class:Dialect
Does this dialect require that integer divisions be wrapped incast()
calls to tell the db parser the expected type.- Overrides:
requiresFloatCastingOfIntegerDivision
in classDialect
- Returns:
- True if integer divisions must be
cast()
ed to float
-
supportsResultSetPositionQueryMethodsOnForwardOnlyCursor
public boolean supportsResultSetPositionQueryMethodsOnForwardOnlyCursor()Description copied from class:Dialect
Does this dialect support asking the result set its positioning information on forward-only cursors?Specifically, in the case of scrolling fetches, Hibernate needs to use
ResultSet.isAfterLast()
andResultSet.isBeforeFirst()
. Certain drivers do not allow access to these methods for forward-only cursors.- Overrides:
supportsResultSetPositionQueryMethodsOnForwardOnlyCursor
in classDialect
- Returns:
- True if methods like
ResultSet.isAfterLast()
andResultSet.isBeforeFirst()
are supported for forward only cursors; false otherwise.
-
supportsCircularCascadeDeleteConstraints
public boolean supportsCircularCascadeDeleteConstraints()Description copied from class:Dialect
Does this dialect support definition of cascade delete constraints which can cause circular chains?- Overrides:
supportsCircularCascadeDeleteConstraints
in classDialect
- Returns:
- True if circular cascade delete constraints are supported; false otherwise.
-
supportsSubselectAsInPredicateLHS
public boolean supportsSubselectAsInPredicateLHS()Description copied from class:Dialect
Is a subselect supported as the left-hand side (LHS) of anIN
predicates?In other words, is syntax like
<subquery> IN (1, 2, 3)
supported?- Overrides:
supportsSubselectAsInPredicateLHS
in classDialect
- Returns:
- True if a subselect can appear as the LHS of an in-predicate; false otherwise.
-
supportsExpectedLobUsagePattern
public boolean supportsExpectedLobUsagePattern()Description copied from class:Dialect
"Expected" LOB usage pattern is such that I can perform an insert via prepared statement with a parameter binding for a LOB value without crazy casting to JDBC driver implementation-specific classes.- Overrides:
supportsExpectedLobUsagePattern
in classDialect
- Returns:
- True if normal LOB usage patterns can be used with this driver; false if driver-specific hookiness needs to be applied.
-
supportsLobValueChangePropagation
public boolean supportsLobValueChangePropagation()Description copied from class:Dialect
Does the dialect support propagating changes to LOB values back to the database? Talking about mutating the internal value of the locator, as opposed to supplying a new locator instance.- For BLOBs, the internal value might be changed by:
Blob.setBinaryStream(long)
,Blob.setBytes(long, byte[])
,Blob.setBytes(long, byte[], int, int)
, orBlob.truncate(long)
. - For CLOBs, the internal value might be changed by:
Clob.setAsciiStream(long)
,Clob.setCharacterStream(long)
,Clob.setString(long, String)
,Clob.setString(long, String, int, int)
, orClob.truncate(long)
.
- Overrides:
supportsLobValueChangePropagation
in classDialect
- Returns:
- True if the changes are propagated back to the database; false otherwise.
- For BLOBs, the internal value might be changed by:
-
supportsUnboundedLobLocatorMaterialization
public boolean supportsUnboundedLobLocatorMaterialization()Description copied from class:Dialect
Is it supported to materialize a LOB locator outside the transaction in which it was created?- Overrides:
supportsUnboundedLobLocatorMaterialization
in classDialect
- Returns:
- True if unbounded materialization is supported; false otherwise.
-
supportsSubqueryOnMutatingTable
public boolean supportsSubqueryOnMutatingTable()Description copied from class:Dialect
Does this dialect support referencing the table being mutated in a subquery? The "table being mutated" is the table referenced in an update or delete query. And so can that table then be referenced in a subquery of the update or delete query?For example, would the following two syntaxes be supported:
delete from TABLE_A where ID not in (select ID from TABLE_A)
update TABLE_A set NON_ID = 'something' where ID in (select ID from TABLE_A)
- Overrides:
supportsSubqueryOnMutatingTable
in classDialect
- Returns:
- True if this dialect allows references the mutating table from a subquery.
-
supportsExistsInSelect
public boolean supportsExistsInSelect()Description copied from class:Dialect
Does the dialect support an exists statement in the select clause?- Overrides:
supportsExistsInSelect
in classDialect
- Returns:
- True if exists checks are allowed in the select clause; false otherwise.
-
doesReadCommittedCauseWritersToBlockReaders
public boolean doesReadCommittedCauseWritersToBlockReaders()Description copied from class:Dialect
For the underlying database, isREAD_COMMITTED
isolation implemented by forcing readers to wait for write locks to be released?- Overrides:
doesReadCommittedCauseWritersToBlockReaders
in classDialect
- Returns:
- True if writers block readers to achieve
READ_COMMITTED
; false otherwise.
-
doesRepeatableReadCauseReadersToBlockWriters
public boolean doesRepeatableReadCauseReadersToBlockWriters()Description copied from class:Dialect
For the underlying database, isREPEATABLE_READ
isolation implemented by forcing writers to wait for read locks to be released?- Overrides:
doesRepeatableReadCauseReadersToBlockWriters
in classDialect
- Returns:
- True if readers block writers to achieve
REPEATABLE_READ
; false otherwise.
-
supportsBindAsCallableArgument
public boolean supportsBindAsCallableArgument()Description copied from class:Dialect
Does this dialect support using a JDBC bind parameter as an argument to a function or procedure call?- Overrides:
supportsBindAsCallableArgument
in classDialect
- Returns:
- Returns
true
if the database supports accepting bind params as args,false
otherwise. The default istrue
.
-
supportsTupleCounts
public boolean supportsTupleCounts()Description copied from class:Dialect
Does this dialect supportcount(a,b)
?- Overrides:
supportsTupleCounts
in classDialect
- Returns:
- True if the database supports counting tuples; false otherwise.
-
requiresParensForTupleCounts
public boolean requiresParensForTupleCounts()Description copied from class:Dialect
IfDialect.supportsTupleCounts()
is true, does this dialect require the tuple to be delimited with parentheses?- Overrides:
requiresParensForTupleCounts
in classDialect
- Returns:
- boolean
-
supportsTupleDistinctCounts
public boolean supportsTupleDistinctCounts()Description copied from class:Dialect
Does this dialect supportcount(distinct a,b)
?- Overrides:
supportsTupleDistinctCounts
in classDialect
- Returns:
- True if the database supports counting distinct tuples; false otherwise.
-
requiresParensForTupleDistinctCounts
public boolean requiresParensForTupleDistinctCounts()Description copied from class:Dialect
IfDialect.supportsTupleDistinctCounts()
is true, does this dialect require the tuple to be delimited with parentheses?- Overrides:
requiresParensForTupleDistinctCounts
in classDialect
- Returns:
- boolean
-
getInExpressionCountLimit
public int getInExpressionCountLimit()Description copied from class:Dialect
Return the limit that the underlying database places on the number of elements in anIN
predicate. If the database defines no such limits, simply return zero or a number smaller than zero.- Overrides:
getInExpressionCountLimit
in classDialect
- Returns:
- The limit, or a non-positive integer to indicate no limit.
-
getParameterCountLimit
public int getParameterCountLimit()Description copied from class:Dialect
Return the limit that the underlying database places on the number of parameters that can be defined for a PreparedStatement. If the database defines no such limits, simply return zero or a number smaller than zero. By default, Dialect returns the same value asDialect.getInExpressionCountLimit()
.- Overrides:
getParameterCountLimit
in classDialect
- Returns:
- The limit, or a non-positive integer to indicate no limit.
-
forceLobAsLastValue
public boolean forceLobAsLastValue()Description copied from class:Dialect
Must LOB values occur last in inserts and updates?- Overrides:
forceLobAsLastValue
in classDialect
- Returns:
- boolean True if Lob values should be last, false if it does not matter.
-
isEmptyStringTreatedAsNull
public boolean isEmptyStringTreatedAsNull()Description copied from class:Dialect
Return whether the dialect considers an empty string value to be null.- Overrides:
isEmptyStringTreatedAsNull
in classDialect
- Returns:
- boolean True if an empty string is treated as null, false otherwise.
-
useFollowOnLocking
Description copied from class:Dialect
Some dialects have trouble applying pessimistic locking depending upon what other query options are specified (paging, ordering, etc). This method allows these dialects to request that locking be applied by subsequent selects.- Overrides:
useFollowOnLocking
in classDialect
- Returns:
true
indicates that the dialect requests that locking be applied by subsequent select;false
(the default) indicates that locking should be applied to the main SQL statement.
-
getUniqueDelegate
Description copied from class:Dialect
Get theUniqueDelegate
supported by this dialect- Overrides:
getUniqueDelegate
in classDialect
- Returns:
- The UniqueDelegate
-
getQueryHintString
Description copied from class:Dialect
Apply a hint to the given SQL query.The entire query is provided, allowing full control over the placement and syntax of the hint.
By default, ignore the hint and simply return the query.
- Overrides:
getQueryHintString
in classDialect
- Parameters:
query
- The query to which to apply the hint.hintList
- The hints to apply- Returns:
- The modified SQL
-
getQueryHintString
Description copied from class:Dialect
Apply a hint to the given SQL query.The entire query is provided, allowing full control over the placement and syntax of the hint.
By default, ignore the hint and simply return the query.
- Overrides:
getQueryHintString
in classDialect
- Parameters:
query
- The query to which to apply the hint.hints
- The hints to apply- Returns:
- The modified SQL
-
defaultScrollMode
Description copied from class:Dialect
A defaultScrollMode
to be used byQuery.scroll()
.- Overrides:
defaultScrollMode
in classDialect
- Returns:
- the default
ScrollMode
to use.
-
supportsOffsetInSubquery
public boolean supportsOffsetInSubquery()Description copied from class:Dialect
Does this dialect supportoffset
in subqueries?For example:
select * from Table1 where col1 in (select col1 from Table2 order by col2 limit 1 offset 1)
- Overrides:
supportsOffsetInSubquery
in classDialect
- Returns:
true
if it does
-
supportsOrderByInSubquery
public boolean supportsOrderByInSubquery()Description copied from class:Dialect
Does this dialect support theorder by
clause in subqueries?For example:
select * from Table1 where col1 in (select col1 from Table2 order by col2 limit 1)
- Overrides:
supportsOrderByInSubquery
in classDialect
- Returns:
true
if it does
-
supportsSubqueryInSelect
public boolean supportsSubqueryInSelect()Description copied from class:Dialect
Does this dialect support subqueries in theselect
clause?For example:
select col1, (select col2 from Table2 where ...) from Table1
- Overrides:
supportsSubqueryInSelect
in classDialect
- Returns:
true
if it does
-
supportsInsertReturning
public boolean supportsInsertReturning()Description copied from class:Dialect
Does this dialect fully support returning arbitrary generated column values after execution of aninsert
statement, using native SQL syntax?Support for identity columns is insufficient here, we require something like:
insert ... returning ...
select from final table (insert ... )
- Overrides:
supportsInsertReturning
in classDialect
- Returns:
true
ifInsertReturningDelegate
works for any sort of primary key column (not just identity columns), orfalse
ifInsertReturningDelegate
does not work, or only works for specialized identity/"autoincrement" columns- See Also:
-
supportsInsertReturningGeneratedKeys
public boolean supportsInsertReturningGeneratedKeys()Description copied from class:Dialect
Does this dialect fully support returning arbitrary generated column values after execution of aninsert
statement, using the JDBC methodConnection.prepareStatement(String, String[])
.Support for returning the generated value of an identity column via the JDBC method
Connection.prepareStatement(String, int)
is insufficient here.- Overrides:
supportsInsertReturningGeneratedKeys
in classDialect
- Returns:
true
ifGetGeneratedKeysDelegate
works for any sort of primary key column (not just identity columns), orfalse
ifGetGeneratedKeysDelegate
does not work, or only works for specialized identity/"autoincrement" columns- See Also:
-
supportsFetchClause
Description copied from class:Dialect
Does this dialect support the givenFETCH
clause type.- Overrides:
supportsFetchClause
in classDialect
- Parameters:
type
- The fetch clause type- Returns:
true
if the underlying database supports the given fetch clause type,false
otherwise. The default isfalse
.
-
supportsWindowFunctions
public boolean supportsWindowFunctions()Description copied from class:Dialect
Does this dialect support window functions likerow_number() over (..)
?- Overrides:
supportsWindowFunctions
in classDialect
- Returns:
true
if the underlying database supports window functions,false
otherwise. The default isfalse
.
-
supportsLateral
public boolean supportsLateral()Description copied from class:Dialect
Does this dialect support the SQLlateral
keyword or a proprietary alternative?- Overrides:
supportsLateral
in classDialect
- Returns:
true
if the underlying database supports lateral,false
otherwise. The default isfalse
.
-
getCallableStatementSupport
Description copied from class:Dialect
TheCallableStatementSupport
for this database. Does this database support returning cursors?- Overrides:
getCallableStatementSupport
in classDialect
-
getNameQualifierSupport
Description copied from class:Dialect
The support for qualified identifiers.By default, decide based on
DatabaseMetaData
.- Overrides:
getNameQualifierSupport
in classDialect
- Returns:
- The
NameQualifierSupport
, or null to useDatabaseMetaData
.
-
getBatchLoadSizingStrategy
Description copied from class:Dialect
The strategy used to determine the appropriate number of keys to load in a single SQL query with batch-fetch loading.- Overrides:
getBatchLoadSizingStrategy
in classDialect
- See Also:
-
getMultiKeyLoadSizingStrategy
Description copied from class:Dialect
The strategy used to determine the appropriate number of keys to load in a single SQL query with multi-key loading.- Overrides:
getMultiKeyLoadSizingStrategy
in classDialect
- See Also:
-
isJdbcLogWarningsEnabledByDefault
public boolean isJdbcLogWarningsEnabledByDefault()Description copied from class:Dialect
Is JDBC statement warning logging enabled by default?- Overrides:
isJdbcLogWarningsEnabledByDefault
in classDialect
-
augmentPhysicalTableTypes
- Overrides:
augmentPhysicalTableTypes
in classDialect
-
augmentRecognizedTableTypes
- Overrides:
augmentRecognizedTableTypes
in classDialect
-
supportsPartitionBy
public boolean supportsPartitionBy()Description copied from class:Dialect
Does is dialect supportpartition by
?- Overrides:
supportsPartitionBy
in classDialect
-
supportsNamedParameters
Description copied from class:Dialect
- Overrides:
supportsNamedParameters
in classDialect
- Throws:
SQLException
- Accessing theDatabaseMetaData
cause an exception. Just rethrow and Hibernate will handle it.
-
getNationalizationSupport
Description copied from class:Dialect
Determines whether this database requires the use of explicitly nationalized character (Unicode) data types.That is, whether the use of
Types.NCHAR
,Types.NVARCHAR
, andTypes.NCLOB
is required for nationalized character data.- Overrides:
getNationalizationSupport
in classDialect
-
getAggregateSupport
Description copied from class:Dialect
How does this dialect support aggregate types likeSqlTypes.STRUCT
.- Overrides:
getAggregateSupport
in classDialect
-
supportsStandardArrays
public boolean supportsStandardArrays()Description copied from class:Dialect
Does this database have native support for ANSI SQL standard arrays which are expressed in terms of the element type name:integer array
.- Overrides:
supportsStandardArrays
in classDialect
- Returns:
- boolean
-
getArrayTypeName
public String getArrayTypeName(String javaElementTypeName, String elementTypeName, Integer maxLength) Description copied from class:Dialect
The SQL type name for the array type with elements of the given type name.The ANSI-standard syntax is
integer array
.- Overrides:
getArrayTypeName
in classDialect
-
appendArrayLiteral
public void appendArrayLiteral(SqlAppender appender, Object[] literal, JdbcLiteralFormatter<Object> elementFormatter, WrapperOptions wrapperOptions) Description copied from class:Dialect
Append an array literal with the given elements to the givenSqlAppender
.- Overrides:
appendArrayLiteral
in classDialect
-
supportsDistinctFromPredicate
public boolean supportsDistinctFromPredicate()Description copied from class:Dialect
Does this dialect support some kind ofdistinct from
predicate?That is, does it support syntax like:
... where FIRST_NAME IS DISTINCT FROM LAST_NAME
- Overrides:
supportsDistinctFromPredicate
in classDialect
- Returns:
- True if this SQL dialect is known to support some kind of
distinct from
predicate; false otherwise
-
getPreferredSqlTypeCodeForArray
public int getPreferredSqlTypeCodeForArray()Description copied from class:Dialect
The JDBC type code to use for mapping properties of basic Java array orCollection
types.Usually
SqlTypes.ARRAY
orSqlTypes.VARBINARY
.- Overrides:
getPreferredSqlTypeCodeForArray
in classDialect
- Returns:
- one of the type codes defined by
SqlTypes
.
-
getPreferredSqlTypeCodeForBoolean
public int getPreferredSqlTypeCodeForBoolean()Description copied from class:Dialect
The JDBC type code to use for mapping properties of Java typeboolean
.Usually
Types.BOOLEAN
orTypes.BIT
.- Overrides:
getPreferredSqlTypeCodeForBoolean
in classDialect
- Returns:
- one of the type codes defined by
Types
.
-
supportsNonQueryWithCTE
public boolean supportsNonQueryWithCTE()Description copied from class:Dialect
Does this dialect support insert, update, and delete statements with Common Table Expressions (CTEs)?- Overrides:
supportsNonQueryWithCTE
in classDialect
- Returns:
true
if non-query statements are supported with CTE
-
supportsRecursiveCTE
public boolean supportsRecursiveCTE()Description copied from class:Dialect
Does this dialect/database support recursive CTEs?- Overrides:
supportsRecursiveCTE
in classDialect
- Returns:
true
if recursive CTEs are supported
-
supportsValuesList
public boolean supportsValuesList()Description copied from class:Dialect
Does this dialect supportvalues
lists of formVALUES (1), (2), (3)
?- Overrides:
supportsValuesList
in classDialect
- Returns:
true
ifvalues
list are supported
-
supportsValuesListForInsert
public boolean supportsValuesListForInsert()Description copied from class:Dialect
Does this dialect supportvalues
lists of formVALUES (1), (2), (3)
in insert statements?- Overrides:
supportsValuesListForInsert
in classDialect
- Returns:
true
ifvalues
list are allowed in insert statements
-
supportsSkipLocked
public boolean supportsSkipLocked()Description copied from class:Dialect
Does this dialect supportSKIP_LOCKED
timeout.- Overrides:
supportsSkipLocked
in classDialect
- Returns:
true
if SKIP_LOCKED is supported
-
supportsNoWait
public boolean supportsNoWait()Description copied from class:Dialect
Does this dialect supportNO_WAIT
timeout.- Overrides:
supportsNoWait
in classDialect
- Returns:
true
ifNO_WAIT
is supported
-
supportsWait
public boolean supportsWait()Description copied from class:Dialect
Does this dialect supportWAIT
timeout.- Overrides:
supportsWait
in classDialect
- Returns:
true
ifWAIT
is supported
-
inlineLiteral
Deprecated, for removal: This API element is subject to removal in a future version.- Overrides:
inlineLiteral
in classDialect
-
appendLiteral
Description copied from class:Dialect
Append a literal string to the givenSqlAppender
.- Overrides:
appendLiteral
in classDialect
-
appendBinaryLiteral
Description copied from class:Dialect
Append a binary literal to the givenSqlAppender
.- Overrides:
appendBinaryLiteral
in classDialect
-
supportsJdbcConnectionLobCreation
Description copied from class:Dialect
Check whether the JDBCConnection
supports creating LOBs viaConnection.createBlob()
,Connection.createNClob()
, orConnection.createClob()
.- Overrides:
supportsJdbcConnectionLobCreation
in classDialect
- Parameters:
databaseMetaData
- JDBCDatabaseMetaData
which can be used if LOB creation is supported only starting from a given driver version- Returns:
true
if LOBs can be created via the JDBC Connection.
-
supportsMaterializedLobAccess
public boolean supportsMaterializedLobAccess()Description copied from class:Dialect
Check whether the JDBC driver allows setting LOBs viaPreparedStatement.setBytes(int, byte[])
,PreparedStatement.setNString(int, String)
, orPreparedStatement.setString(int, String)
APIs.- Overrides:
supportsMaterializedLobAccess
in classDialect
- Returns:
true
if LOBs can be set with the materialized APIs.
-
useMaterializedLobWhenCapacityExceeded
public boolean useMaterializedLobWhenCapacityExceeded()Description copied from class:Dialect
Whether to switch:- from
VARCHAR
-like types toSqlTypes.MATERIALIZED_CLOB
types when the requested size for a type exceeds theDialect.getMaxVarcharCapacity()
, - from
NVARCHAR
-like types toSqlTypes.MATERIALIZED_NCLOB
types when the requested size for a type exceeds theDialect.getMaxNVarcharCapacity()
, and - from
VARBINARY
-like types toSqlTypes.MATERIALIZED_BLOB
types when the requested size for a type exceeds theDialect.getMaxVarbinaryCapacity()
.
- Overrides:
useMaterializedLobWhenCapacityExceeded
in classDialect
- Returns:
true
if materialized LOBs should be used for capacity exceeding types.
- from
-
addSqlHintOrComment
Description copied from class:Dialect
Modify the SQL, adding hints or comments, if necessary- Overrides:
addSqlHintOrComment
in classDialect
-
prependComment
Description copied from class:Dialect
Prepend a comment to the given SQL fragment.- Overrides:
prependComment
in classDialect
-
escapeComment
-
getHqlTranslator
Description copied from class:Dialect
Return anHqlTranslator
specific to this dialect, ornull
to use the standard translator.Note that
QueryEngineOptions.getCustomHqlTranslator()
has higher precedence since it comes directly from the user config.- Overrides:
getHqlTranslator
in classDialect
- See Also:
-
getSqmTranslatorFactory
Description copied from class:Dialect
Return aSqmTranslatorFactory
specific to this dialect, ornull
to use the standard translator.Note that
QueryEngineOptions.getCustomSqmTranslatorFactory()
has higher precedence since it comes directly from the user config.- Overrides:
getSqmTranslatorFactory
in classDialect
- See Also:
-
getSqlAstTranslatorFactory
Description copied from class:Dialect
- Overrides:
getSqlAstTranslatorFactory
in classDialect
- See Also:
-
getGroupBySelectItemReferenceStrategy
Description copied from class:Dialect
Determine how selected items are referenced in thegroup by
clause.- Overrides:
getGroupBySelectItemReferenceStrategy
in classDialect
-
getSizeStrategy
Description copied from class:Dialect
A customDialect.SizeStrategy
for column types.- Overrides:
getSizeStrategy
in classDialect
-
getMaxVarcharLength
public int getMaxVarcharLength()Description copied from class:Dialect
The biggest size value that can be supplied as argument to aTypes.VARCHAR
-like type.For longer column lengths, use some sort of
text
-like type for the column.- Overrides:
getMaxVarcharLength
in classDialect
-
getMaxNVarcharLength
public int getMaxNVarcharLength()Description copied from class:Dialect
The biggest size value that can be supplied as argument to aTypes.NVARCHAR
-like type.For longer column lengths, use some sort of
ntext
-like type for the column.- Overrides:
getMaxNVarcharLength
in classDialect
-
getMaxVarbinaryLength
public int getMaxVarbinaryLength()Description copied from class:Dialect
The biggest size value that can be supplied as argument to aTypes.VARBINARY
-like type.For longer column lengths, use some sort of
image
-like type for the column.- Overrides:
getMaxVarbinaryLength
in classDialect
-
getMaxVarcharCapacity
public int getMaxVarcharCapacity()Description copied from class:Dialect
The longest possible length of aTypes.VARCHAR
-like column.For longer column lengths, use some sort of
clob
-like type for the column.- Overrides:
getMaxVarcharCapacity
in classDialect
-
getMaxNVarcharCapacity
public int getMaxNVarcharCapacity()Description copied from class:Dialect
The longest possible length of aTypes.NVARCHAR
-like column.For longer column lengths, use some sort of
nclob
-like type for the column.- Overrides:
getMaxNVarcharCapacity
in classDialect
-
getMaxVarbinaryCapacity
public int getMaxVarbinaryCapacity()Description copied from class:Dialect
The longest possible length of aTypes.VARBINARY
-like column.For longer column lengths, use some sort of
blob
-like type for the column.- Overrides:
getMaxVarbinaryCapacity
in classDialect
-
getDefaultLobLength
public long getDefaultLobLength()Description copied from class:Dialect
This is the default length for a generated column of typeBLOB
orCLOB
mapped toBlob
orClob
, if LOB columns have a length in this dialect.- Overrides:
getDefaultLobLength
in classDialect
- Returns:
- 1048576L by default
- See Also:
-
getDefaultDecimalPrecision
public int getDefaultDecimalPrecision()Description copied from class:Dialect
This is the default precision for a generated column of exact numeric typeDECIMAL
orNUMERIC
mapped to aBigInteger
orBigDecimal
.Usually returns the maximum precision of the database, except when there is no such maximum precision, or the maximum precision is very high.
- Overrides:
getDefaultDecimalPrecision
in classDialect
- Returns:
- the default precision, in decimal digits
- See Also:
-
getDefaultTimestampPrecision
public int getDefaultTimestampPrecision()Description copied from class:Dialect
This is the default precision for a generated column of typeTIMESTAMP
mapped to aTimestamp
orLocalDateTime
.Usually 6 (microseconds) or 3 (milliseconds).
- Overrides:
getDefaultTimestampPrecision
in classDialect
- Returns:
- the default precision, in decimal digits, of the fractional seconds field
- See Also:
-
getFloatPrecision
public int getFloatPrecision()Description copied from class:Dialect
This is the default precision for a generated column mapped to a JavaFloat
orfloat
. That is, a value representing "single precision".Usually 24 binary digits, at least for databases with a conventional interpretation of the ANSI SQL specification.
- Overrides:
getFloatPrecision
in classDialect
- Returns:
- a value representing "single precision", usually in binary digits, but sometimes in decimal digits
-
getDoublePrecision
public int getDoublePrecision()Description copied from class:Dialect
This is the default precision for a generated column mapped to a JavaDouble
ordouble
. That is, a value representing "double precision".Usually 53 binary digits, at least for databases with a conventional interpretation of the ANSI SQL specification.
- Overrides:
getDoublePrecision
in classDialect
- Returns:
- a value representing "double precision", usually in binary digits, but sometimes in decimal digits
-
getFractionalSecondPrecisionInNanos
public long getFractionalSecondPrecisionInNanos()Description copied from class:Dialect
The "native" precision for arithmetic with datetimes and day-to-second durations. Datetime differences will be calculated with this precision except when a precision is explicitly specified as aTemporalUnit
.Usually 1 (nanoseconds), 1_000 (microseconds), or 1_000_000 (milliseconds).
- Overrides:
getFractionalSecondPrecisionInNanos
in classDialect
- Returns:
- the precision, specified as a quantity of nanoseconds
- See Also:
-
supportsBitType
public boolean supportsBitType()Description copied from class:Dialect
Does this dialect have a true SQLBIT
type with just two values (0 and 1) or, even better, a proper SQLBOOLEAN
type, or doesTypes.BIT
get mapped to a numeric type with more than two values?- Overrides:
supportsBitType
in classDialect
- Returns:
- true if there is a
BIT
orBOOLEAN
type
-
supportsPredicateAsExpression
public boolean supportsPredicateAsExpression()Description copied from class:Dialect
Whether a predicate likea > 0
can appear in an expression context, for example, in aselect
list item.- Overrides:
supportsPredicateAsExpression
in classDialect
-
getLockRowIdentifier
Description copied from class:Dialect
Obtain aRowLockStrategy
for the givenLockMode
.- Overrides:
getLockRowIdentifier
in classDialect
-
generatedAs
Description copied from class:Dialect
Thegenerated as
clause, or similar, for generated column declarations in DDL statements.- Overrides:
generatedAs
in classDialect
- Parameters:
generatedAs
- a SQL expression used to generate the column value- Returns:
- The
generated as
clause containing the given expression
-
hasDataTypeBeforeGeneratedAs
public boolean hasDataTypeBeforeGeneratedAs()Description copied from class:Dialect
Is an explicit column type required forgenerated as
columns?- Overrides:
hasDataTypeBeforeGeneratedAs
in classDialect
- Returns:
true
if an explicit type is required
-
createOptionalTableUpdateOperation
public MutationOperation createOptionalTableUpdateOperation(EntityMutationTarget mutationTarget, OptionalTableUpdate optionalTableUpdate, SessionFactoryImplementor factory) Description copied from class:Dialect
Create aMutationOperation
for a updating an optional table- Overrides:
createOptionalTableUpdateOperation
in classDialect
-
canDisableConstraints
public boolean canDisableConstraints()Description copied from class:Dialect
Is there some way to disable foreign key constraint checking while truncating tables? (If there's no way to do it, and if we can't batch truncate, we must drop and recreate the constraints instead.)- Overrides:
canDisableConstraints
in classDialect
- Returns:
true
if there is some way to do it- See Also:
-
getDisableConstraintsStatement
Description copied from class:Dialect
A SQL statement that temporarily disables foreign key constraint checking for all tables.- Overrides:
getDisableConstraintsStatement
in classDialect
-
getEnableConstraintsStatement
Description copied from class:Dialect
A SQL statement that re-enables foreign key constraint checking for all tables.- Overrides:
getEnableConstraintsStatement
in classDialect
-
getDisableConstraintStatement
Description copied from class:Dialect
A SQL statement that temporarily disables checking of the given foreign key constraint.- Overrides:
getDisableConstraintStatement
in classDialect
- Parameters:
tableName
- the name of the tablename
- the name of the constraint
-
getEnableConstraintStatement
Description copied from class:Dialect
A SQL statement that re-enables checking of the given foreign key constraint.- Overrides:
getEnableConstraintStatement
in classDialect
- Parameters:
tableName
- the name of the tablename
- the name of the constraint
-
canBatchTruncate
public boolean canBatchTruncate()Description copied from class:Dialect
Does thetruncate table
statement accept multiple tables?- Overrides:
canBatchTruncate
in classDialect
- Returns:
true
if it does
-
getTruncateTableStatements
Description copied from class:Dialect
A SQL statement or statements that truncate the given tables.- Overrides:
getTruncateTableStatements
in classDialect
- Parameters:
tableNames
- the names of the tables
-
getTruncateTableStatement
Description copied from class:Dialect
A SQL statement that truncates the given table.- Overrides:
getTruncateTableStatement
in classDialect
- Parameters:
tableName
- the name of the table
-
appendDatetimeFormat
Description copied from class:Dialect
Translate the given datetime format string from the pattern language defined by Java'sDateTimeFormatter
to whatever pattern language is understood by the native datetime formatting function for this database (often theto_char()
function).Since it's never possible to translate every pattern letter sequences understood by
DateTimeFormatter
, only the following subset of pattern letters is accepted by Hibernate:- G: era
- y: year of era
- Y: year of week-based year
- M: month of year
- w: week of week-based year (ISO week number)
- W: week of month
- E: day of week (name)
- e: day of week (number)
- d: day of month
- D: day of year
- a: AM/PM
- H: hour of day (24 hour time)
- h: hour of AM/PM (12 hour time)
- m: minutes
- s: seconds
- z,Z,x: timezone offset
In addition, punctuation characters and single-quoted literal strings are accepted.
Appends a pattern accepted by the function that formats dates and times in this dialect to a SQL fragment that is being constructed.
- Overrides:
appendDatetimeFormat
in classDialect
-
translateExtractField
Description copied from class:Dialect
Return the name used to identify the given field as an argument to theextract()
function, or of this dialect's equivalent function.This method does not need to handle
TemporalUnit.NANOSECOND
,TemporalUnit.NATIVE
,TemporalUnit.OFFSET
,TemporalUnit.DATE
,TemporalUnit.TIME
,TemporalUnit.WEEK_OF_YEAR
, norTemporalUnit.WEEK_OF_MONTH
, which are already desugared byExtractFunction
.- Overrides:
translateExtractField
in classDialect
-
translateDurationField
Description copied from class:Dialect
Return the name used to identify the given unit of duration as an argument to#timestampadd()
or#timestampdiff()
, or of this dialect's equivalent functions.This method does not need to handle
TemporalUnit.NANOSECOND
,TemporalUnit.NATIVE
,TemporalUnit.OFFSET
,TemporalUnit.DAY_OF_WEEK
,TemporalUnit.DAY_OF_MONTH
,TemporalUnit.DAY_OF_YEAR
,TemporalUnit.DATE
,TemporalUnit.TIME
,TemporalUnit.TIMEZONE_HOUR
,TemporalUnit.TIMEZONE_MINUTE
,TemporalUnit.WEEK_OF_YEAR
, norTemporalUnit.WEEK_OF_MONTH
, which are not units of duration.- Overrides:
translateDurationField
in classDialect
-
appendDateTimeLiteral
public void appendDateTimeLiteral(SqlAppender appender, TemporalAccessor temporalAccessor, TemporalType precision, TimeZone jdbcTimeZone) Description copied from class:Dialect
Append a datetime literal representing the givenjava.time
value to the givenSqlAppender
.- Overrides:
appendDateTimeLiteral
in classDialect
-
appendDateTimeLiteral
public void appendDateTimeLiteral(SqlAppender appender, Date date, TemporalType precision, TimeZone jdbcTimeZone) Description copied from class:Dialect
Append a datetime literal representing the givenDate
value to the givenSqlAppender
.- Overrides:
appendDateTimeLiteral
in classDialect
-
appendDateTimeLiteral
public void appendDateTimeLiteral(SqlAppender appender, Calendar calendar, TemporalType precision, TimeZone jdbcTimeZone) Description copied from class:Dialect
Append a datetime literal representing the givenCalendar
value to the givenSqlAppender
.- Overrides:
appendDateTimeLiteral
in classDialect
-
appendIntervalLiteral
Description copied from class:Dialect
Append a literal SQLinterval
representing the given JavaDuration
.- Overrides:
appendIntervalLiteral
in classDialect
-
appendUUIDLiteral
Description copied from class:Dialect
Append a literal SQLuuid
representing the given JavaUUID
.This is usually a
cast()
expression, but it might be a function call.- Overrides:
appendUUIDLiteral
in classDialect
-
supportsTemporalLiteralOffset
public boolean supportsTemporalLiteralOffset()Description copied from class:Dialect
Does this dialect supports timezone offsets in temporal literals.- Overrides:
supportsTemporalLiteralOffset
in classDialect
-
getTimeZoneSupport
Description copied from class:Dialect
How the dialect supports time zone types likeTypes.TIMESTAMP_WITH_TIMEZONE
.- Overrides:
getTimeZoneSupport
in classDialect
-
rowId
Description copied from class:Dialect
The name of arowid
-like pseudo-column which acts as a high-performance row locator, or null if this dialect has no such pseudo-column.If the
rowid
-like value is an explicitly-declared named column instead of an implicit pseudo-column, and if the given name is nonempty, return the given name.- Overrides:
rowId
in classDialect
- Parameters:
rowId
- the name specified byRowId.value()
, which is ignored ifDialect.getRowIdColumnString(java.lang.String)
is not overridden
-
rowIdSqlType
public int rowIdSqlType()Description copied from class:Dialect
The JDBC type code of therowid
-like pseudo-column which acts as a high-performance row locator.- Overrides:
rowIdSqlType
in classDialect
- Returns:
Types.ROWID
by default
-
getRowIdColumnString
Description copied from class:Dialect
If this dialect requires that therowid
column be declared explicitly, return the DDL column definition.- Overrides:
getRowIdColumnString
in classDialect
- Returns:
- the DDL column definition, or
null
if therowid
is an implicit pseudo-column
-