Class SybaseASELegacyDialect

java.lang.Object
org.hibernate.dialect.Dialect
org.hibernate.dialect.AbstractTransactSQLDialect
org.hibernate.community.dialect.SybaseLegacyDialect
org.hibernate.community.dialect.SybaseASELegacyDialect
All Implemented Interfaces:
org.hibernate.boot.model.FunctionContributor, org.hibernate.boot.model.TypeContributor, org.hibernate.exception.spi.ConversionContext

public class SybaseASELegacyDialect extends SybaseLegacyDialect
A SQL dialect for Sybase Adaptive Server Enterprise 11.9 and above.
  • Nested Class Summary

    Nested classes/interfaces inherited from class org.hibernate.dialect.Dialect

    org.hibernate.dialect.Dialect.SizeStrategy, org.hibernate.dialect.Dialect.SizeStrategyImpl
  • Field Summary

    Fields inherited from class org.hibernate.community.dialect.SybaseLegacyDialect

    jtdsDriver

    Fields inherited from class org.hibernate.dialect.Dialect

    CLOSED_QUOTE, FALSE_STRING_VALUES, LEGACY_LOB_MERGE_STRATEGY, LOG_BASE2OF10, NEW_LOCATOR_LOB_MERGE_STRATEGY, QUOTE, STANDARD_MULTI_KEY_LOAD_SIZING_STRATEGY, STREAM_XFER_LOB_MERGE_STRATEGY, TRUE_STRING_VALUES
  • Constructor Summary

    Constructors
    Constructor
    Description
     
    SybaseASELegacyDialect(org.hibernate.dialect.DatabaseVersion version)
     
    SybaseASELegacyDialect(org.hibernate.engine.jdbc.dialect.spi.DialectResolutionInfo info)
     
  • Method Summary

    Modifier and Type
    Method
    Description
    appendLockHint(org.hibernate.LockOptions mode, String tableName)
     
    org.hibernate.exception.spi.SQLExceptionConversionDelegate
     
    protected String
    columnType(int sqlTypeCode)
     
    void
    contributeTypes(org.hibernate.boot.model.TypeContributions typeContributions, org.hibernate.service.ServiceRegistry serviceRegistry)
     
     
     
     
    org.hibernate.dialect.aggregate.AggregateSupport
     
    int
     
     
    int
     
    long
     
    org.hibernate.dialect.pagination.LimitHandler
     
    org.hibernate.dialect.lock.spi.LockingSupport
     
    int
     
    int
     
    protected int
    Sybase ASE doesn't support the generate_series function or lateral recursive CTEs, so it has to be emulated with the xmltable and replicate functions.
    int
     
    int
     
    org.hibernate.dialect.Dialect.SizeStrategy
     
    org.hibernate.sql.ast.SqlAstTranslatorFactory
     
     
    org.hibernate.exception.spi.ViolatedConstraintNameExtractor
     
    void
    initializeFunctionRegistry(org.hibernate.boot.model.FunctionContributions functionContributions)
     
    boolean
     
    protected void
    registerColumnTypes(org.hibernate.boot.model.TypeContributions typeContributions, org.hibernate.service.ServiceRegistry serviceRegistry)
     
    protected void
     
    boolean
    The Sybase ASE BIT type does not allow null values, so we don't use it.
    boolean
     
    boolean
     
    boolean
     
    boolean
     
    boolean
     
    boolean
     
    boolean
     
    boolean
     
    boolean
     
    boolean
     
    timestampaddPattern(org.hibernate.query.common.TemporalUnit unit, TemporalType temporalType, org.hibernate.query.sqm.IntervalType intervalType)
     
    timestampdiffPattern(org.hibernate.query.common.TemporalUnit unit, TemporalType fromTemporalType, TemporalType toTemporalType)
     
     

    Methods inherited from class org.hibernate.dialect.AbstractTransactSQLDialect

    appendBinaryLiteral, applyLocksToSql, doesReadCommittedCauseWritersToBlockReaders, doesRepeatableReadCauseReadersToBlockWriters, getAddColumnString, getCurrentTimestampSelectString, getDefaultStatementBatchSize, getFallbackSqmInsertStrategy, getFallbackSqmMutationStrategy, getForUpdateString, getIdentityColumnSupport, getLocalTemporaryTableStrategy, getLockingClauseStrategy, getNullOrdering, getPreferredSqlTypeCodeForBoolean, getResultSet, getSelectGUIDString, getSupportedTemporaryTableKind, getTemporaryTableAfterUseAction, getTemporaryTableBeforeUseAction, getTemporaryTableCreateCommand, isCurrentTimestampSelectStringCallable, qualifyIndexName, registerResultSetOutParameter, replaceLtrimRtrim, requiresCastForConcatenatingNonStrings, supportsCurrentTimestampSelection, supportsExistsInSelect, supportsTupleDistinctCounts, trimPattern

    Methods inherited from class org.hibernate.dialect.Dialect

    addPartitionKeyToPrimaryKey, addSqlHintOrComment, addUseIndexQueryHint, appendArrayLiteral, appendBooleanValueString, appendCheckConstraintOptions, appendIntervalLiteral, appendIntervalLiteral, appendLiteral, appendUUIDLiteral, augmentPhysicalTableTypes, augmentRecognizedTableTypes, buildLockingClauseStrategy, buildOptimisticForceIncrementStrategy, buildOptimisticStrategy, buildPessimisticForceIncrementStrategy, buildPessimisticReadStrategy, buildPessimisticWriteStrategy, buildReadStrategy, buildStringToBooleanCast, buildStringToBooleanCastDecode, buildStringToBooleanDecode, canBatchTruncate, canCreateCatalog, canDisableConstraints, castType, checkVersion, closeQuote, contribute, contributeFunctions, createOptionalTableUpdateOperation, currentLocalTime, currentLocalTimestamp, currentTimestampWithTimeZone, defaultScrollMode, determineDatabaseVersion, doesRoundTemporalOnOverflow, dropConstraints, equivalentTypes, escapeComment, forceLobAsLastValue, generatedAs, getAddColumnSuffixString, getAddForeignKeyConstraintString, getAddForeignKeyConstraintString, getAddPrimaryKeyConstraintString, getAlterColumnTypeString, getAlterTableString, getArrayTypeName, getAuxiliaryDatabaseObjectExporter, getBatchLoadSizingStrategy, getBeforeDropStatement, getCascadeConstraintsString, getCaseInsensitiveLike, getCatalogSeparator, getCheckCondition, getCheckCondition, getCheckCondition, getCheckCondition, getCheckCondition, getCheckCondition, getCheckConstraintString, getColumnAliasExtractor, getColumnComment, getCreateCatalogCommand, getCreateEnumTypeCommand, getCreateEnumTypeCommand, getCreateIndexString, getCreateIndexTail, getCreateMultisetTableString, getCreateSchemaCommand, getCreateTableString, getCreateTemporaryTableColumnAnnotation, getCreateUserDefinedTypeExtensionsString, getCreateUserDefinedTypeKindString, getCrossReferenceParentTableFilter, getDefaultDecimalPrecision, getDefaultIntervalSecondScale, getDefaultLobLength, getDefaultNonContextualLobCreation, getDefaultOrdinalityColumnName, getDefaultProperties, getDefaultTimestampPrecision, getDefaultUseGetGeneratedKeys, getDisableConstraintsStatement, getDisableConstraintStatement, getDropCatalogCommand, getDropEnumTypeCommand, getDropEnumTypeCommand, getDropForeignKeyString, getDropSchemaCommand, getDropTableString, getDropUniqueKeyString, getEnableConstraintsStatement, getEnableConstraintStatement, getEnumTypeDeclaration, getEnumTypeDeclaration, getFallbackSchemaManagementTool, getForeignKeyExporter, getForUpdateNowaitString, getForUpdateNowaitString, getForUpdateSkipLockedString, getForUpdateSkipLockedString, getForUpdateString, getForUpdateString, getForUpdateString, getForUpdateString, getForUpdateString, getForUpdateString, getForUpdateString, getFromDualForSelectOnly, getFunctionalDependencyAnalysisSupport, getGlobalTemporaryTableStrategy, getGroupBySelectItemReferenceStrategy, getHqlTranslator, getIndexExporter, getKeywords, getLobMergeStrategy, getLockingStrategy, getLockingStrategy, getLockRowIdentifier, getLowercaseFunction, getMaxNVarcharCapacity, getMaxNVarcharLength, getMaxVarbinaryCapacity, getMaxVarbinaryLength, getMaxVarcharCapacity, getMinimumSupportedVersion, getMultiKeyLoadSizingStrategy, getNativeIdentifierGeneratorStrategy, getNativeParameterMarkerStrategy, getNativeValueGenerationStrategy, getNoColumnsInsertString, getNullColumnString, getParameterCountLimit, getPersistentTemporaryTableStrategy, getPessimisticLockStyle, getQueryHintString, getQueryHintString, getQuerySequencesString, getReadLockString, getReadLockString, getReadLockString, getReadLockString, getReadRowLockStrategy, getResultSet, getResultSet, getRowIdColumnString, getSchemaNameResolver, getSelectClauseNullString, getSelectClauseNullString, getSequenceExporter, getSequenceInformationExtractor, getSequenceSupport, getTableCleaner, getTableComment, getTableExporter, getTableMigrator, getTemporaryTableCreateOptions, getTemporaryTableDdlTransactionHandling, getTemporaryTableDropCommand, getTemporaryTableExporter, getTemporaryTableTruncateCommand, getTimeoutInSeconds, getTimeZoneSupport, getTruncateTableStatement, getTruncateTableStatements, getUniqueKeyExporter, getUserDefinedTypeComment, getUserDefinedTypeExporter, getVersion, getWriteLockString, getWriteLockString, getWriteLockString, getWriteLockString, getWriteRowLockStrategy, hasAlterTable, hasDataTypeBeforeGeneratedAs, hasSelfReferentialForeignKeyBug, initDefaultProperties, isEmptyStringTreatedAsNull, isJdbcLogWarningsEnabledByDefault, isLob, openQuote, ordinal, prependComment, quote, quoteCollation, registerKeyword, registerKeywords, registerResultSetOutParameter, requiresColumnListInCreateView, requiresFloatCastingOfIntegerDivision, requiresParensForTupleCounts, requiresParensForTupleDistinctCounts, resolveSqlTypeCode, resolveSqlTypeCode, rowId, rowIdSqlType, stripsTrailingSpacesFromChar, supportsAlterColumnType, supportsArrayConstructor, supportsBatchUpdates, supportsBindAsCallableArgument, supportsBindingNullForSetObject, supportsBindingNullSqlTypeForSetNull, supportsCaseInsensitiveLike, supportsCircularCascadeDeleteConstraints, supportsColumnCheck, supportsCommentOn, supportsConflictClauseForInsertCTE, supportsDuplicateSelectItemsInQueryGroup, supportsFetchClause, supportsFilterClause, supportsForUpdate, supportsIfExistsAfterAlterTable, supportsIfExistsAfterConstraintName, supportsIfExistsAfterTableName, supportsIfExistsAfterTypeName, supportsIfExistsBeforeConstraintName, supportsIfExistsBeforeTableName, supportsIfExistsBeforeTypeName, supportsInsertReturning, supportsInsertReturningGeneratedKeys, supportsInsertReturningRowId, supportsIsTrue, supportsJdbcConnectionLobCreation, supportsJoinInMutationStatementSubquery, supportsLateral, supportsLockTimeouts, supportsMaterializedLobAccess, supportsNationalizedMethods, supportsNestedSubqueryCorrelation, supportsNestedWithClause, supportsNoColumnsInsert, supportsNonQueryWithCTE, supportsNoWait, supportsOffsetInSubquery, supportsOrdinalSelectItemReference, supportsOuterJoinForUpdate, supportsPredicateAsExpression, supportsRecursiveCTE, supportsRecursiveCycleClause, supportsRecursiveCycleUsingClause, supportsRecursiveSearchClause, supportsRefCursors, supportsResultSetPositionQueryMethodsOnForwardOnlyCursor, supportsRowConstructor, supportsRowValueConstructorDistinctFromSyntax, supportsRowValueConstructorGtLtSyntax, supportsRowValueConstructorSyntaxInInSubQuery, supportsSimpleQueryGrouping, supportsSkipLocked, supportsStandardArrays, supportsSubqueryInSelect, supportsSubqueryOnMutatingTable, supportsSubselectAsInPredicateLHS, supportsTableCheck, supportsTableOptions, supportsTemporalLiteralOffset, supportsTemporaryTablePrimaryKey, supportsTemporaryTables, supportsTruncateWithCast, supportsTupleCounts, supportsUnboundedLobLocatorMaterialization, supportsUnionAll, supportsUpdateReturning, supportsUserDefinedTypes, supportsValuesList, supportsValuesListForInsert, supportsWait, supportsWindowFunctions, supportsWithClauseInSubquery, toBooleanValueString, toString, transformSelectString, translateDurationField, unquoteGetGeneratedKeys, useArrayForMultiValuedParameters, useConnectionToCreateLob, useCrossReferenceForeignKeys, useFollowOnLocking, useInputStreamToInsertBlob, useMaterializedLobWhenCapacityExceeded

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
  • Constructor Details

    • SybaseASELegacyDialect

      public SybaseASELegacyDialect()
    • SybaseASELegacyDialect

      public SybaseASELegacyDialect(org.hibernate.dialect.DatabaseVersion version)
    • SybaseASELegacyDialect

      public SybaseASELegacyDialect(org.hibernate.engine.jdbc.dialect.spi.DialectResolutionInfo info)
  • Method Details

    • columnType

      protected String columnType(int sqlTypeCode)
      Overrides:
      columnType in class org.hibernate.dialect.AbstractTransactSQLDialect
    • registerColumnTypes

      protected void registerColumnTypes(org.hibernate.boot.model.TypeContributions typeContributions, org.hibernate.service.ServiceRegistry serviceRegistry)
      Overrides:
      registerColumnTypes in class org.hibernate.dialect.Dialect
    • getPreferredSqlTypeCodeForArray

      public int getPreferredSqlTypeCodeForArray()
      Overrides:
      getPreferredSqlTypeCodeForArray in class org.hibernate.dialect.Dialect
    • getMaxVarcharLength

      public int getMaxVarcharLength()
      Overrides:
      getMaxVarcharLength in class org.hibernate.dialect.Dialect
    • initializeFunctionRegistry

      public void initializeFunctionRegistry(org.hibernate.boot.model.FunctionContributions functionContributions)
      Overrides:
      initializeFunctionRegistry in class SybaseLegacyDialect
    • getMaximumSeriesSize

      protected int getMaximumSeriesSize()
      Sybase ASE doesn't support the generate_series function or lateral recursive CTEs, so it has to be emulated with the xmltable and replicate functions.
    • isAnsiNullOn

      public boolean isAnsiNullOn()
    • getFloatPrecision

      public int getFloatPrecision()
      Overrides:
      getFloatPrecision in class org.hibernate.dialect.Dialect
    • getDoublePrecision

      public int getDoublePrecision()
      Overrides:
      getDoublePrecision in class org.hibernate.dialect.Dialect
    • getSizeStrategy

      public org.hibernate.dialect.Dialect.SizeStrategy getSizeStrategy()
      Overrides:
      getSizeStrategy in class SybaseLegacyDialect
    • getSqlAstTranslatorFactory

      public org.hibernate.sql.ast.SqlAstTranslatorFactory getSqlAstTranslatorFactory()
      Overrides:
      getSqlAstTranslatorFactory in class SybaseLegacyDialect
    • getAggregateSupport

      public org.hibernate.dialect.aggregate.AggregateSupport getAggregateSupport()
      Overrides:
      getAggregateSupport in class org.hibernate.dialect.Dialect
    • supportsBitType

      public boolean supportsBitType()
      The Sybase ASE BIT type does not allow null values, so we don't use it.
      Overrides:
      supportsBitType in class org.hibernate.dialect.Dialect
      Returns:
      false
    • supportsDistinctFromPredicate

      public boolean supportsDistinctFromPredicate()
      Overrides:
      supportsDistinctFromPredicate in class org.hibernate.dialect.Dialect
    • contributeTypes

      public void contributeTypes(org.hibernate.boot.model.TypeContributions typeContributions, org.hibernate.service.ServiceRegistry serviceRegistry)
      Overrides:
      contributeTypes in class SybaseLegacyDialect
    • currentDate

      public String currentDate()
      Overrides:
      currentDate in class org.hibernate.dialect.Dialect
    • currentTime

      public String currentTime()
      Overrides:
      currentTime in class org.hibernate.dialect.Dialect
    • currentTimestamp

      public String currentTimestamp()
      Overrides:
      currentTimestamp in class org.hibernate.dialect.Dialect
    • getFractionalSecondPrecisionInNanos

      public long getFractionalSecondPrecisionInNanos()
      Overrides:
      getFractionalSecondPrecisionInNanos in class org.hibernate.dialect.Dialect
    • timestampaddPattern

      public String timestampaddPattern(org.hibernate.query.common.TemporalUnit unit, TemporalType temporalType, org.hibernate.query.sqm.IntervalType intervalType)
      Overrides:
      timestampaddPattern in class SybaseLegacyDialect
    • timestampdiffPattern

      public String timestampdiffPattern(org.hibernate.query.common.TemporalUnit unit, TemporalType fromTemporalType, TemporalType toTemporalType)
      Overrides:
      timestampdiffPattern in class SybaseLegacyDialect
    • registerDefaultKeywords

      protected void registerDefaultKeywords()
      Overrides:
      registerDefaultKeywords in class org.hibernate.dialect.Dialect
    • supportsCascadeDelete

      public boolean supportsCascadeDelete()
      Overrides:
      supportsCascadeDelete in class org.hibernate.dialect.Dialect
    • getMaxAliasLength

      public int getMaxAliasLength()
      Overrides:
      getMaxAliasLength in class org.hibernate.dialect.Dialect
    • getMaxIdentifierLength

      public int getMaxIdentifierLength()
      Overrides:
      getMaxIdentifierLength in class SybaseLegacyDialect
    • getLockingSupport

      public org.hibernate.dialect.lock.spi.LockingSupport getLockingSupport()
      Overrides:
      getLockingSupport in class SybaseLegacyDialect
    • supportsOrderByInSubquery

      public boolean supportsOrderByInSubquery()
      Overrides:
      supportsOrderByInSubquery in class org.hibernate.dialect.Dialect
    • supportsUnionInSubquery

      public boolean supportsUnionInSubquery()
      Overrides:
      supportsUnionInSubquery in class org.hibernate.dialect.Dialect
    • supportsPartitionBy

      public boolean supportsPartitionBy()
      Overrides:
      supportsPartitionBy in class org.hibernate.dialect.AbstractTransactSQLDialect
    • getTableTypeString

      public String getTableTypeString()
      Overrides:
      getTableTypeString in class org.hibernate.dialect.Dialect
    • supportsExpectedLobUsagePattern

      public boolean supportsExpectedLobUsagePattern()
      Overrides:
      supportsExpectedLobUsagePattern in class org.hibernate.dialect.Dialect
    • supportsLobValueChangePropagation

      public boolean supportsLobValueChangePropagation()
      Overrides:
      supportsLobValueChangePropagation in class org.hibernate.dialect.Dialect
    • appendLockHint

      public String appendLockHint(org.hibernate.LockOptions mode, String tableName)
      Overrides:
      appendLockHint in class org.hibernate.dialect.AbstractTransactSQLDialect
    • toQuotedIdentifier

      public String toQuotedIdentifier(String name)
      Overrides:
      toQuotedIdentifier in class org.hibernate.dialect.Dialect
    • getViolatedConstraintNameExtractor

      public org.hibernate.exception.spi.ViolatedConstraintNameExtractor getViolatedConstraintNameExtractor()
      Specified by:
      getViolatedConstraintNameExtractor in interface org.hibernate.exception.spi.ConversionContext
      Overrides:
      getViolatedConstraintNameExtractor in class org.hibernate.dialect.Dialect
    • buildSQLExceptionConversionDelegate

      public org.hibernate.exception.spi.SQLExceptionConversionDelegate buildSQLExceptionConversionDelegate()
      Overrides:
      buildSQLExceptionConversionDelegate in class org.hibernate.dialect.Dialect
    • getLimitHandler

      public org.hibernate.dialect.pagination.LimitHandler getLimitHandler()
      Overrides:
      getLimitHandler in class org.hibernate.dialect.Dialect
    • getDual

      public String getDual()
      Overrides:
      getDual in class org.hibernate.dialect.Dialect
    • supportsIntersect

      public boolean supportsIntersect()
      Overrides:
      supportsIntersect in class org.hibernate.dialect.Dialect
    • supportsJoinsInDelete

      public boolean supportsJoinsInDelete()
      Overrides:
      supportsJoinsInDelete in class org.hibernate.dialect.Dialect
    • supportsCrossJoin

      public boolean supportsCrossJoin()
      Overrides:
      supportsCrossJoin in class org.hibernate.dialect.Dialect