public class Cache71Dialect extends Dialect
| Property Name | Property Value |
|---|---|
| hibernate.dialect | org.hibernate.dialect.Cache71Dialect |
| hibernate.connection.driver_class | com.intersys.jdbc.CacheDriver |
| hibernate.connection.username | (see note 1) |
| hibernate.connection.password | (see note 1) |
| hibernate.connection.url | jdbc:Cache://127.0.0.1:1972/USER |
etc\CacheSequences.xml
For example, at the COS terminal prompt in the namespace, run the
following command:
d LoadFile^%apiOBJ("c:\hibernate\etc\CacheSequences.xml","ck")
In your Hibernate mapping you can specify sequence use.
For example, the following shows the use of a sequence generator in a Hibernate mapping:
<id name="id" column="uid" type="long" unsaved-value="null">
<generator class="sequence"/>
</id>
| Modifier and Type | Field and Description |
|---|---|
static ViolatedConstraintNameExtracter |
EXTRACTER
The Cache ViolatedConstraintNameExtracter.
|
CLOSED_QUOTE, DEFAULT_BATCH_SIZE, LEGACY_LOB_MERGE_STRATEGY, NEW_LOCATOR_LOB_MERGE_STRATEGY, NO_BATCH, QUOTE, STANDARD_DEFAULT_BATCH_LOAD_SIZING_STRATEGY, STREAM_XFER_LOB_MERGE_STRATEGY| Constructor and Description |
|---|
Cache71Dialect()
Creates new
Cache71Dialect instance. |
| Modifier and Type | Method and Description |
|---|---|
boolean |
areStringComparisonsCaseInsensitive()
Are string comparisons implicitly case insensitive.
|
boolean |
bindLimitParametersFirst()
Does the LIMIT clause come at the start of the
SELECT statement, rather than at the end?
|
SQLExceptionConversionDelegate |
buildSQLExceptionConversionDelegate()
Build an instance of a
SQLExceptionConversionDelegate for
interpreting dialect-specific error or SQLState codes. |
protected void |
commonRegistration() |
JoinFragment |
createOuterJoinFragment()
Create a
JoinFragment strategy responsible
for handling this dialect's variations in how joins are handled. |
boolean |
dropConstraints()
Do we need to drop constraints before dropping tables in this dialect?
|
String |
getAddColumnString()
The syntax used to add a column to a table (optional).
|
String |
getAddForeignKeyConstraintString(String constraintName,
String[] foreignKey,
String referencedTable,
String[] primaryKey,
boolean referencesPrimaryKey)
The syntax used to add a foreign key constraint to a table.
|
String |
getCascadeConstraintsString()
Completely optional cascading drop clause
|
MultiTableBulkIdStrategy |
getDefaultMultiTableBulkIdStrategy() |
IdentityColumnSupport |
getIdentityColumnSupport()
Get the appropriate
IdentityColumnSupport |
LimitHandler |
getLimitHandler()
Returns the delegate managing LIMIT clause.
|
String |
getLimitString(String sql,
boolean hasOffset)
Apply s limit clause to the query.
|
LockingStrategy |
getLockingStrategy(Lockable lockable,
LockMode lockMode)
Get a strategy instance which knows how to acquire a database-level lock
of the specified mode for this dialect.
|
String |
getLowercaseFunction()
The name of the SQL function that transforms a string to
lowercase
|
String |
getNativeIdentifierGeneratorStrategy()
Resolves the native generation strategy associated to this dialect.
|
String |
getNoColumnsInsertString()
The fragment used to insert a row without specifying any column values.
|
String |
getNullColumnString()
The keyword used to specify a nullable column.
|
ResultSet |
getResultSet(CallableStatement ps)
Given a callable statement previously processed by
Dialect.registerResultSetOutParameter(java.sql.CallableStatement, int),
extract the ResultSet from the OUT parameter. |
ViolatedConstraintNameExtracter |
getViolatedConstraintNameExtracter() |
boolean |
hasAlterTable()
Does this dialect support the ALTER TABLE syntax?
|
boolean |
hasSelfReferentialForeignKeyBug()
Does the database/driver have bug in deleting rows that refer to other rows being deleted in the same query?
|
boolean |
qualifyIndexName()
Do we need to qualify index names with the schema name?
|
protected void |
register71Functions() |
int |
registerResultSetOutParameter(CallableStatement statement,
int col)
Registers a parameter (either OUT, or the new REF_CURSOR param type available in Java 8) capable of
returning
ResultSet *by position*. |
boolean |
supportsCascadeDelete()
Does this dialect support cascaded delete on foreign key definitions?
|
boolean |
supportsCheck()
Does this dialect support check constraints?
|
boolean |
supportsEmptyInList()
Does this dialect support empty IN lists?
For example, is [where XYZ in ()] a supported construct?
|
boolean |
supportsLimit()
Does this dialect support some form of limiting query results
via a SQL clause?
|
boolean |
supportsLimitOffset()
Does this dialect's LIMIT support (if any) additionally
support specifying an offset?
|
boolean |
supportsOuterJoinForUpdate()
Does this dialect support FOR UPDATE in conjunction with
outer joined rows?
|
boolean |
supportsResultSetPositionQueryMethodsOnForwardOnlyCursor()
Does this dialect support asking the result set its positioning
information on forward only cursors.
|
boolean |
supportsSequences()
Does this dialect support sequences?
|
boolean |
supportsVariableLimit()
Does this dialect support bind variables (i.e., prepared statement
parameters) for its limit/offset?
|
boolean |
useMaxForLimit()
Does the LIMIT clause take a "maximum" row number instead
of a total number of returned rows?
This is easiest understood via an example.
|
appendLockHint, appendLockHint, applyLocksToSql, bindLimitParametersInReverseOrder, buildIdentifierHelper, buildSQLExceptionConverter, canCreateCatalog, canCreateSchema, cast, cast, cast, closeQuote, contributeTypes, convertToFirstRowValue, createCaseFragment, defaultScrollMode, doesReadCommittedCauseWritersToBlockReaders, doesRepeatableReadCauseReadersToBlockWriters, forceLimitUsage, forceLobAsLastValue, forUpdateOfColumns, getAddColumnSuffixString, getAddForeignKeyConstraintString, getAddPrimaryKeyConstraintString, getAddUniqueConstraintString, getAuxiliaryDatabaseObjectExporter, getCallableStatementSupport, getCaseInsensitiveLike, getCastTypeName, getColumnAliasExtractor, getColumnComment, getCreateCatalogCommand, getCreateMultisetTableString, getCreateSchemaCommand, getCreateSequenceString, getCreateSequenceString, getCreateSequenceStrings, getCreateSequenceStrings, getCreateTableString, getCrossJoinSeparator, getCurrentSchemaCommand, getCurrentTimestampSelectString, getCurrentTimestampSQLFunctionName, getDefaultBatchLoadSizingStrategy, getDefaultProperties, getDialect, getDialect, getDropCatalogCommand, getDropForeignKeyString, getDropSchemaCommand, getDropSequenceString, getDropSequenceStrings, getDropTableString, getForeignKeyExporter, getForUpdateNowaitString, getForUpdateNowaitString, getForUpdateSkipLockedString, getForUpdateSkipLockedString, getForUpdateString, getForUpdateString, getForUpdateString, getForUpdateString, getForUpdateString, getFunctions, getHibernateTypeName, getHibernateTypeName, getIndexExporter, getInExpressionCountLimit, getKeywords, getLimitString, getLobMergeStrategy, getMaxAliasLength, getNameQualifierSupport, getNativeIdentifierGeneratorClass, getNotExpression, getQueryHintString, getQuerySequencesString, getReadLockString, getResultSet, getResultSet, getSchemaNameResolver, getSelectClauseNullString, getSelectGUIDString, getSelectSequenceNextValString, getSequenceExporter, getSequenceInformationExtractor, getSequenceNextValString, getSqlTypeDescriptorOverride, getTableComment, getTableExporter, getTableTypeString, getTypeName, getTypeName, getUniqueDelegate, getUniqueKeyExporter, getWriteLockString, isCurrentTimestampSelectStringCallable, isJdbcLogWarningsEnabledByDefault, isLockTimeoutParameterized, openQuote, quote, registerColumnType, registerColumnType, registerFunction, registerHibernateType, registerHibernateType, registerKeyword, registerResultSetOutParameter, remapSqlTypeDescriptor, renderOrderByElement, replaceResultVariableInOrderByClauseWithPosition, requiresCastingOfParametersInSelectClause, requiresParensForTupleDistinctCounts, supportsBindAsCallableArgument, supportsCaseInsensitiveLike, supportsCircularCascadeDeleteConstraints, supportsColumnCheck, supportsCommentOn, supportsCurrentTimestampSelection, supportsExistsInSelect, supportsExpectedLobUsagePattern, supportsIfExistsAfterConstraintName, supportsIfExistsAfterTableName, supportsIfExistsBeforeConstraintName, supportsIfExistsBeforeTableName, supportsLobValueChangePropogation, supportsLockTimeouts, supportsNamedParameters, supportsNationalizedTypes, supportsNotNullUnique, supportsParametersInInsertSelect, supportsPooledSequences, supportsRowValueConstructorSyntax, supportsRowValueConstructorSyntaxInInList, supportsSubqueryOnMutatingTable, supportsSubselectAsInPredicateLHS, supportsTableCheck, supportsTupleCounts, supportsTupleDistinctCounts, supportsTuplesInSubqueries, supportsUnboundedLobLocatorMaterialization, supportsUnionAll, supportsUnique, supportsUniqueConstraintInCreateAlterTable, toBooleanValueString, toString, transformSelectString, useFollowOnLocking, useInputStreamToInsertBlobpublic static final ViolatedConstraintNameExtracter EXTRACTER
public Cache71Dialect()
Cache71Dialect instance. Sets up the JDBC /
Caché type mappings.protected final void commonRegistration()
protected final void register71Functions()
public boolean hasAlterTable()
DialecthasAlterTable in class Dialectpublic boolean qualifyIndexName()
DialectqualifyIndexName in class Dialectpublic String getAddForeignKeyConstraintString(String constraintName, String[] foreignKey, String referencedTable, String[] primaryKey, boolean referencesPrimaryKey)
DialectgetAddForeignKeyConstraintString in class DialectconstraintName - The FK constraint name.foreignKey - The names of the columns comprising the FKreferencedTable - The table referenced by the FKprimaryKey - The explicit columns in the referencedTable referenced
by this FK.referencesPrimaryKey - if false, constraint should be
explicit about which column names the constraint refers topublic boolean supportsCheck()
false (Cache does not support check constraints)public String getAddColumnString()
DialectgetAddColumnString in class Dialectpublic String getCascadeConstraintsString()
DialectgetCascadeConstraintsString in class Dialectpublic boolean dropConstraints()
DialectdropConstraints in class Dialectpublic boolean supportsCascadeDelete()
DialectsupportsCascadeDelete in class Dialecttrue indicates that the dialect does support cascaded delete on foreign keys.public boolean hasSelfReferentialForeignKeyBug()
DialecthasSelfReferentialForeignKeyBug in class Dialecttrue if the database/driver has this bugpublic MultiTableBulkIdStrategy getDefaultMultiTableBulkIdStrategy()
getDefaultMultiTableBulkIdStrategy in class Dialectpublic String getNativeIdentifierGeneratorStrategy()
DialectgetNativeIdentifierGeneratorStrategy in class Dialectpublic IdentityColumnSupport getIdentityColumnSupport()
DialectIdentityColumnSupportgetIdentityColumnSupport in class Dialectpublic boolean supportsSequences()
DialectsupportsSequences in class Dialectpublic boolean supportsOuterJoinForUpdate()
DialectsupportsOuterJoinForUpdate in class Dialectpublic LockingStrategy getLockingStrategy(Lockable lockable, LockMode lockMode)
DialectgetLockingStrategy in class Dialectlockable - The persister for the entity to be locked.lockMode - The type of lock to be acquired.public LimitHandler getLimitHandler()
DialectgetLimitHandler in class Dialectpublic boolean supportsLimit()
DialectsupportsLimit in class Dialectpublic boolean supportsLimitOffset()
DialectsupportsLimitOffset in class Dialectpublic boolean supportsVariableLimit()
DialectsupportsVariableLimit in class Dialectpublic boolean bindLimitParametersFirst()
DialectbindLimitParametersFirst in class Dialectpublic boolean useMaxForLimit()
DialectuseMaxForLimit in class Dialectpublic String getLimitString(String sql, boolean hasOffset)
Dialectvariable
limit clauses when they support limits. Thus, when building the
select command we do not actually need to know the limit or the offest
since we will just be using placeholders.
Here we do still pass along whether or not an offset was specified
so that dialects not supporting offsets can generate proper exceptions.
In general, dialects will override one or the other of this method and
Dialect.getLimitString(String, int, int).getLimitString in class Dialectsql - The query to which to apply the limit.hasOffset - Is the query requesting an offset?public int registerResultSetOutParameter(CallableStatement statement, int col) throws SQLException
DialectResultSet *by position*. Pre-Java 8, registering such ResultSet-returning
parameters varied greatly across database and drivers; hence its inclusion as part of the Dialect contract.registerResultSetOutParameter in class Dialectstatement - The callable statement.col - The bind position at which to register the output param.SQLException - Indicates problems registering the param.public ResultSet getResultSet(CallableStatement ps) throws SQLException
DialectDialect.registerResultSetOutParameter(java.sql.CallableStatement, int),
extract the ResultSet from the OUT parameter.getResultSet in class Dialectps - The callable statement.SQLException - Indicates problems extracting the result set.public String getLowercaseFunction()
DialectgetLowercaseFunction in class Dialectpublic String getNullColumnString()
DialectgetNullColumnString in class Dialectpublic JoinFragment createOuterJoinFragment()
DialectJoinFragment strategy responsible
for handling this dialect's variations in how joins are handled.createOuterJoinFragment in class DialectJoinFragment strategy.public String getNoColumnsInsertString()
DialectgetNoColumnsInsertString in class Dialectpublic SQLExceptionConversionDelegate buildSQLExceptionConversionDelegate()
DialectSQLExceptionConversionDelegate for
interpreting dialect-specific error or SQLState codes.
When Dialect.buildSQLExceptionConverter() returns null, the default
SQLExceptionConverter is used to interpret SQLState and
error codes. If this method is overridden to return a non-null value,
the default SQLExceptionConverter will use the returned
SQLExceptionConversionDelegate in addition to the following
standard delegates:
buildSQLExceptionConversionDelegate in class Dialectpublic ViolatedConstraintNameExtracter getViolatedConstraintNameExtracter()
getViolatedConstraintNameExtracter in interface ConversionContextgetViolatedConstraintNameExtracter in class Dialectpublic boolean supportsEmptyInList()
DialectsupportsEmptyInList in class Dialectpublic boolean areStringComparisonsCaseInsensitive()
DialectareStringComparisonsCaseInsensitive in class Dialectpublic boolean supportsResultSetPositionQueryMethodsOnForwardOnlyCursor()
DialectResultSet.isAfterLast() and
ResultSet.isBeforeFirst(). Certain drivers do not
allow access to these methods for forward only cursors.
NOTE : this is highly driver dependent!supportsResultSetPositionQueryMethodsOnForwardOnlyCursor in class DialectResultSet.isAfterLast() and
ResultSet.isBeforeFirst() are supported for forward
only cursors; false otherwise.Copyright © 2017 JBoss by Red Hat. All rights reserved.