站内搜索: 请输入搜索关键词
当前页面: 在线文档首页 > Hibernate 3.2.3 正式版 API 英文文档

MimerSQLDialect (Hibernate API Documentation) - Hibernate 3.2.3 正式版 API 英文文档


org.hibernate.dialect
Class MimerSQLDialect

java.lang.Object
  extended byorg.hibernate.dialect.Dialect
      extended byorg.hibernate.dialect.MimerSQLDialect

public class MimerSQLDialect
extends Dialect

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.

Author:
Fredrik 舕und

Field Summary
 
Fields inherited from class org.hibernate.dialect.Dialect
CLOSED_QUOTE, DEFAULT_BATCH_SIZE, NO_BATCH, QUOTE
 
Constructor Summary
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).
 
Method Summary
 boolean dropConstraints()
          We do not have to drop constraints before we drop the table
 boolean forUpdateOfColumns()
          Does the FOR UPDATE OF syntax specify particular columns?
 String getAddColumnString()
          The syntax used to add a column to a table
 String getCascadeConstraintsString()
          The syntax for using cascade on constraints
 String getCreateSequenceString(String sequenceName)
          The syntax used to create a sequence.
 String getDropSequenceString(String sequenceName)
          The syntax used to drop sequences
 String getQuerySequencesString()
          The syntax for fetching all sequnces avialable in the current schema.
 String getSequenceNextValString(String sequenceName)
          The syntax used to get the next value of a sequence in Mimer SQL
 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.
 boolean supportsIdentityColumns()
          TODO: Check if Mimer SQL cannot handle the way DB2 does
 boolean supportsLimit()
          Mimer SQL does not support limit
 boolean supportsOuterJoinForUpdate()
          For now, simply return false since we don't updatable result sets.
 boolean supportsSequences()
          Mimer SQL supports sequences
 
Methods inherited from class org.hibernate.dialect.Dialect
appendIdentitySelectToInsert, appendLockHint, applyLocksToSql, areStringComparisonsCaseInsensitive, bindLimitParametersFirst, bindLimitParametersInReverseOrder, buildSQLExceptionConverter, closeQuote, createCaseFragment, createOuterJoinFragment, doesReadCommittedCauseWritersToBlockReaders, doesRepeatableReadCauseReadersToBlockWriters, dropTemporaryTableAfterUse, generateTemporaryTableName, getAddForeignKeyConstraintString, getAddPrimaryKeyConstraintString, getCastTypeName, getColumnComment, getCreateMultisetTableString, getCreateSequenceString, getCreateSequenceStrings, getCreateSequenceStrings, getCreateTableString, getCreateTemporaryTablePostfix, getCreateTemporaryTableString, getCurrentTimestampSelectString, getCurrentTimestampSQLFunctionName, getDefaultProperties, getDialect, getDialect, getDropForeignKeyString, getDropSequenceStrings, getForUpdateNowaitString, getForUpdateNowaitString, getForUpdateString, getForUpdateString, getForUpdateString, getFunctions, getHibernateTypeName, getHibernateTypeName, getIdentityColumnString, getIdentityColumnString, getIdentityInsertString, getIdentitySelectString, getIdentitySelectString, getKeywords, getLimitString, getLimitString, getLockingStrategy, getLowercaseFunction, getMaxAliasLength, getNativeIdentifierGeneratorClass, getNoColumnsInsertString, getNullColumnString, getResultSet, getSelectClauseNullString, getSelectGUIDString, getSelectSequenceNextValString, getTableComment, getTableTypeString, getTypeName, getTypeName, getViolatedConstraintNameExtracter, hasAlterTable, hasDataTypeInIdentityColumn, hasSelfReferentialForeignKeyBug, isCurrentTimestampSelectStringCallable, openQuote, performTemporaryTableDDLInIsolation, qualifyIndexName, quote, registerColumnType, registerColumnType, registerFunction, registerHibernateType, registerHibernateType, registerKeyword, registerResultSetOutParameter, supportsBindAsCallableArgument, supportsCascadeDelete, supportsCircularCascadeDeleteConstraints, supportsColumnCheck, supportsCommentOn, supportsCurrentTimestampSelection, supportsEmptyInList, supportsExistsInSelect, supportsExpectedLobUsagePattern, supportsIfExistsAfterTableName, supportsIfExistsBeforeTableName, supportsInsertSelectIdentity, supportsLimitOffset, supportsLobValueChangePropogation, supportsNotNullUnique, supportsParametersInInsertSelect, supportsPooledSequences, supportsResultSetPositionQueryMethodsOnForwardOnlyCursor, supportsRowValueConstructorSyntax, supportsRowValueConstructorSyntaxInInList, supportsSubqueryOnMutatingTable, supportsSubselectAsInPredicateLHS, supportsTableCheck, supportsTemporaryTables, supportsUnboundedLobLocatorMaterialization, supportsUnionAll, supportsUnique, supportsUniqueConstraintInCreateAlterTable, supportsVariableLimit, toBooleanValueString, toString, transformSelectString, useInputStreamToInsertBlob, useMaxForLimit
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

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 Detail

getAddColumnString

public String getAddColumnString()
The syntax used to add a column to a table

Overrides:
getAddColumnString in class Dialect
Returns:
The "add column" fragment.

dropConstraints

public boolean dropConstraints()
We do not have to drop constraints before we drop the table

Overrides:
dropConstraints in class Dialect
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:
supportsIdentityColumns in class Dialect
Returns:
True if IDENTITY columns are supported; false otherwise.

supportsSequences

public boolean supportsSequences()
Mimer SQL supports sequences

Overrides:
supportsSequences in class Dialect
Returns:
boolean

getSequenceNextValString

public String getSequenceNextValString(String sequenceName)
The syntax used to get the next value of a sequence in Mimer SQL

Overrides:
getSequenceNextValString in class Dialect
Parameters:
sequenceName - the name of the sequence
Returns:
String The "nextval" select string.

getCreateSequenceString

public String getCreateSequenceString(String sequenceName)
The syntax used to create a sequence. Since we presume the sequences will be used as keys, we make them unique.

Overrides:
getCreateSequenceString in class Dialect
Parameters:
sequenceName - The name of the sequence
Returns:
The sequence creation command

getDropSequenceString

public String getDropSequenceString(String sequenceName)
The syntax used to drop sequences

Overrides:
getDropSequenceString in class Dialect
Parameters:
sequenceName - The name of the sequence
Returns:
The sequence drop commands

supportsLimit

public boolean supportsLimit()
Mimer SQL does not support limit

Overrides:
supportsLimit in class Dialect
Returns:
True if this dialect supports some form of LIMIT.

getCascadeConstraintsString

public String getCascadeConstraintsString()
The syntax for using cascade on constraints

Overrides:
getCascadeConstraintsString in class Dialect
Returns:
String

getQuerySequencesString

public String getQuerySequencesString()
The syntax for fetching all sequnces avialable in the current schema.

Overrides:
getQuerySequencesString in class Dialect
Returns:
The select command; or null if sequences are not supported.
See Also:
SchemaUpdate

forUpdateOfColumns

public boolean forUpdateOfColumns()
Does the FOR UPDATE OF syntax specify particular columns?

Overrides:
forUpdateOfColumns in class Dialect
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:
supportsOuterJoinForUpdate in class Dialect
Returns:
True if outer joined rows can be locked via FOR UPDATE.