Package org.hibernate.dialect
Class MimerSQLDialect
java.lang.Object
org.hibernate.dialect.Dialect
org.hibernate.dialect.MimerSQLDialect
An Hibernate 3 SQL dialect for Mimer SQL. This dialect requires Mimer SQL 9.2.1 or later
because of the mappings to NCLOB, BINARY, and BINARY VARYING.
-
Field Summary
Fields inherited from class org.hibernate.dialect.Dialect
CLOSED_QUOTE, DEFAULT_BATCH_SIZE, NO_BATCH, QUOTE -
Constructor Summary
ConstructorsConstructorDescriptionEven thoug Mimer SQL supports character and binary columns up to 15 000 in lenght, this is also the maximum width of the table (exluding LOBs). -
Method Summary
Modifier and TypeMethodDescriptionbooleanWe do not have to drop constraints before we drop the tablebooleanDoes the FOR UPDATE OF syntax specify particular columns?The syntax used to add a column to a tableThe syntax for using cascade on constraintsgetCreateSequenceString(String sequenceName) The syntax used to create a sequence.getDropSequenceString(String sequenceName) The syntax used to drop sequencesThe syntax for fetching all sequnces avialable in the current schema.getSequenceNextValString(String sequenceName) The syntax used to get the next value of a sequence in Mimer SQLbooleanSupport the FOR UPDATE syntax? For now, returns false since the current version of the Mimer SQL JDBC Driver does not support updatable resultsets.booleanTODO: Check if Mimer SQL cannot handle the way DB2 doesbooleanMimer SQL does not support limitbooleanFor now, simply return false since we don't updatable result sets.booleanMimer SQL supports sequencesMethods inherited from class org.hibernate.dialect.Dialect
addTypeOverride, appendIdentitySelectToInsert, appendLockHint, applyLocksToSql, areStringComparisonsCaseInsensitive, bindLimitParametersFirst, bindLimitParametersInReverseOrder, buildSQLExceptionConverter, closeQuote, convertToFirstRowValue, createCaseFragment, createOuterJoinFragment, doesReadCommittedCauseWritersToBlockReaders, doesRepeatableReadCauseReadersToBlockWriters, dropTemporaryTableAfterUse, forceLimitUsage, generateTemporaryTableName, getAddForeignKeyConstraintString, getAddPrimaryKeyConstraintString, getCastTypeName, getColumnAliasExtractor, getColumnComment, getCreateMultisetTableString, getCreateSequenceString, getCreateSequenceStrings, getCreateSequenceStrings, getCreateTableString, getCreateTemporaryTablePostfix, getCreateTemporaryTableString, getCrossJoinSeparator, getCurrentTimestampSelectString, getCurrentTimestampSQLFunctionName, getDefaultProperties, getDialect, getDialect, getDropForeignKeyString, getDropSequenceStrings, getDropTemporaryTableString, getForUpdateNowaitString, getForUpdateNowaitString, getForUpdateString, getForUpdateString, getForUpdateString, getForUpdateString, getForUpdateString, getFunctions, getHibernateTypeName, getHibernateTypeName, getIdentityColumnString, getIdentityColumnString, getIdentityInsertString, getIdentitySelectString, getIdentitySelectString, getKeywords, getLimitString, getLimitString, getLockingStrategy, getLowercaseFunction, getMaxAliasLength, getNativeIdentifierGeneratorClass, getNoColumnsInsertString, getNullColumnString, getReadLockString, getResultSet, getSelectClauseNullString, getSelectGUIDString, getSelectSequenceNextValString, getTableComment, getTableTypeString, getTypeName, getTypeName, getTypeOverrides, getViolatedConstraintNameExtracter, getWriteLockString, hasAlterTable, hasDataTypeInIdentityColumn, hasSelfReferentialForeignKeyBug, isCurrentTimestampSelectStringCallable, isLockTimeoutParameterized, openQuote, performTemporaryTableDDLInIsolation, qualifyIndexName, quote, registerColumnType, registerColumnType, registerFunction, registerHibernateType, registerHibernateType, registerKeyword, registerResultSetOutParameter, replaceResultVariableInOrderByClauseWithPosition, requiresCastingOfParametersInSelectClause, supportsBindAsCallableArgument, supportsCascadeDelete, supportsCircularCascadeDeleteConstraints, supportsColumnCheck, supportsCommentOn, supportsCurrentTimestampSelection, supportsEmptyInList, supportsExistsInSelect, supportsExpectedLobUsagePattern, supportsIfExistsAfterTableName, supportsIfExistsBeforeTableName, supportsInsertSelectIdentity, supportsLimitOffset, supportsLobValueChangePropogation, supportsLockTimeouts, supportsNotNullUnique, supportsParametersInInsertSelect, supportsPooledSequences, supportsResultSetPositionQueryMethodsOnForwardOnlyCursor, supportsRowValueConstructorSyntax, supportsRowValueConstructorSyntaxInInList, supportsSubqueryOnMutatingTable, supportsSubselectAsInPredicateLHS, supportsTableCheck, supportsTemporaryTables, supportsTupleCounts, supportsTupleDistinctCounts, supportsUnboundedLobLocatorMaterialization, supportsUnionAll, supportsUnique, supportsUniqueConstraintInCreateAlterTable, supportsVariableLimit, toBooleanValueString, toString, transformSelectString, useInputStreamToInsertBlob, useMaxForLimit
-
Constructor Details
-
MimerSQLDialect
public MimerSQLDialect()Even thoug Mimer SQL supports character and binary columns up to 15 000 in lenght, this is also the maximum width of the table (exluding LOBs). To avoid breaking the limit all the time we limit the length of the character columns to CHAR_MAX_LENTH, NATIONAL_CHAR_LENGTH for national characters, and BINARY_MAX_LENGTH for binary types.
-
-
Method Details
-
getAddColumnString
The syntax used to add a column to a table- Overrides:
getAddColumnStringin classDialect- Returns:
- The "add column" fragment.
-
dropConstraints
public boolean dropConstraints()We do not have to drop constraints before we drop the table- Overrides:
dropConstraintsin classDialect- Returns:
- True if constraints must be dropped prior to dropping the table; false otherwise.
-
supportsIdentityColumns
public boolean supportsIdentityColumns()TODO: Check if Mimer SQL cannot handle the way DB2 does- Overrides:
supportsIdentityColumnsin classDialect- Returns:
- True if IDENTITY columns are supported; false otherwise.
-
supportsSequences
public boolean supportsSequences()Mimer SQL supports sequences- Overrides:
supportsSequencesin classDialect- Returns:
- boolean
-
getSequenceNextValString
The syntax used to get the next value of a sequence in Mimer SQL- Overrides:
getSequenceNextValStringin classDialect- Parameters:
sequenceName- the name of the sequence- Returns:
- String The "nextval" select string.
-
getCreateSequenceString
The syntax used to create a sequence. Since we presume the sequences will be used as keys, we make them unique.- Overrides:
getCreateSequenceStringin classDialect- Parameters:
sequenceName- The name of the sequence- Returns:
- The sequence creation command
-
getDropSequenceString
The syntax used to drop sequences- Overrides:
getDropSequenceStringin classDialect- Parameters:
sequenceName- The name of the sequence- Returns:
- The sequence drop commands
-
supportsLimit
public boolean supportsLimit()Mimer SQL does not support limit- Overrides:
supportsLimitin classDialect- Returns:
- True if this dialect supports some form of LIMIT.
-
getCascadeConstraintsString
The syntax for using cascade on constraints- Overrides:
getCascadeConstraintsStringin classDialect- Returns:
- String
-
getQuerySequencesString
The syntax for fetching all sequnces avialable in the current schema.- Overrides:
getQuerySequencesStringin classDialect- Returns:
- The select command; or null if sequences are not supported.
- See Also:
-
forUpdateOfColumns
public boolean forUpdateOfColumns()Does the FOR UPDATE OF syntax specify particular columns?- Overrides:
forUpdateOfColumnsin classDialect- Returns:
- True if the database supports FOR UPDATE OF syntax; false otherwise.
-
supportsForUpdate
public boolean supportsForUpdate()Support the FOR UPDATE syntax? For now, returns false since the current version of the Mimer SQL JDBC Driver does not support updatable resultsets. Otherwise, Mimer SQL actually supports the for update syntax.- Returns:
- boolean
-
supportsOuterJoinForUpdate
public boolean supportsOuterJoinForUpdate()For now, simply return false since we don't updatable result sets.- Overrides:
supportsOuterJoinForUpdatein classDialect- Returns:
- True if outer joined rows can be locked via FOR UPDATE.
-