Top Description Constructors Methods
org.hibernate.dialect

public Class SybaseASE15Dialect

extends SybaseDialect
Class Inheritance
Known Direct Subclasses
org.hibernate.dialect.SybaseASE157Dialect
Imports
java.sql.Types, org.hibernate.dialect.function.AnsiTrimEmulationFunction, .NoArgSQLFunction, .SQLFunctionTemplate, .VarArgsSQLFunction, org.hibernate.engine.jdbc.env.spi.NameQualifierSupport, org.hibernate.type.StandardBasicTypes, org.hibernate.type.descriptor.sql.SqlTypeDescriptor, .TinyIntTypeDescriptor

An SQL dialect targeting Sybase Adaptive Server Enterprise (ASE) 15 and higher.

TODO : verify if this also works with 12/12.5

Author
Gavin King

Constructor Summary

AccessConstructor and Description
public
SybaseASE15Dialect()

Constructs a SybaseASE15Dialect

Method Summary

Modifier and TypeMethod and Description
public boolean
areStringComparisonsCaseInsensitive()

Overrides org.hibernate.dialect.Dialect.areStringComparisonsCaseInsensitive.

By default, Sybase string comparisons are case-insensitive.
public String
getCrossJoinSeparator()

Overrides org.hibernate.dialect.Dialect.getCrossJoinSeparator.

Returns the separator to use for defining cross joins when translating HQL queries.
public String
getCurrentTimestampSQLFunctionName()

Overrides org.hibernate.dialect.Dialect.getCurrentTimestampSQLFunctionName.

The name of the database-specific SQL function for retrieving the current timestamp.
public int
getMaxAliasLength()

Overrides org.hibernate.dialect.Dialect.getMaxAliasLength.

What is the maximum length Hibernate can use for generated aliases?
public NameQualifierSupport
getNameQualifierSupport()

Overrides org.hibernate.dialect.SybaseDialect.getNameQualifierSupport.

By default interpret this based on DatabaseMetaData.
protected SqlTypeDescriptor
getSqlTypeDescriptorOverride(int
A Types constant indicating the SQL column type
sqlCode
)

Overrides org.hibernate.dialect.SybaseDialect.getSqlTypeDescriptorOverride.

Returns the SqlTypeDescriptor that should be used to handle the given JDBC type code.
private void
public boolean
supportsCascadeDelete()

Overrides org.hibernate.dialect.Dialect.supportsCascadeDelete.

Does this dialect support cascaded delete on foreign key definitions?
public boolean

Returns:

false.

True if normal LOB usage patterns can be used with this driver; false if driver-specific hookiness needs to be applied.

supportsExpectedLobUsagePattern
()

Overrides org.hibernate.dialect.Dialect.supportsExpectedLobUsagePattern.

Actually Sybase does not support LOB locators at al.
public boolean
supportsLockTimeouts()

Overrides org.hibernate.dialect.Dialect.supportsLockTimeouts.

Informational metadata about whether this dialect is known to support specifying timeouts for requested lock acquisitions.
public boolean
supportsPartitionBy()

Overrides org.hibernate.dialect.AbstractTransactSQLDialect.supportsPartitionBy.

Does the underlying database support partition by
Inherited from org.hibernate.dialect.SybaseDialect:
buildIdentifierHelpercanCreateSchemagetCurrentSchemaCommandgetInExpressionCountLimitgetNullColumnString

Constructor Detail

SybaseASE15Dialectback to summary
public SybaseASE15Dialect()

Constructs a SybaseASE15Dialect

Method Detail

areStringComparisonsCaseInsensitiveback to summary
public boolean areStringComparisonsCaseInsensitive()

Overrides org.hibernate.dialect.Dialect.areStringComparisonsCaseInsensitive.

Doc from org.hibernate.dialect.Dialect.areStringComparisonsCaseInsensitive.

By default, Sybase string comparisons are case-insensitive.

If the DB is configured to be case-sensitive, then this return value will be incorrect.

Are string comparisons implicitly case insensitive.

In other words, does [where 'XYZ' = 'xyz'] resolve to true?

Returns:boolean

True if comparisons are case insensitive.

Annotations
@Override
getCrossJoinSeparatorback to summary
public String getCrossJoinSeparator()

Overrides org.hibernate.dialect.Dialect.getCrossJoinSeparator.

Doc from org.hibernate.dialect.Dialect.getCrossJoinSeparator.

Returns the separator to use for defining cross joins when translating HQL queries.

Typically this will be either [ cross join ] or [, ]

Note that the spaces are important!

Returns:String

The cross join separator

Annotations
@Override
getCurrentTimestampSQLFunctionNameback to summary
public String getCurrentTimestampSQLFunctionName()

Overrides org.hibernate.dialect.Dialect.getCurrentTimestampSQLFunctionName.

Doc from org.hibernate.dialect.Dialect.getCurrentTimestampSQLFunctionName.

The name of the database-specific SQL function for retrieving the current timestamp.

Returns:String

The function name.

Annotations
@Override
getMaxAliasLengthback to summary
public int getMaxAliasLength()

Overrides org.hibernate.dialect.Dialect.getMaxAliasLength.

Doc from org.hibernate.dialect.Dialect.getMaxAliasLength.

What is the maximum length Hibernate can use for generated aliases?

The maximum here should account for the fact that Hibernate often needs to append "uniqueing" information to the end of generated aliases. That "uniqueing" information will be added to the end of a identifier generated to the length specified here; so be sure to leave some room (generally speaking 5 positions will suffice).

Returns:int

The maximum length.

Annotations
@Override
getNameQualifierSupportback to summary
public NameQualifierSupport getNameQualifierSupport()

Overrides org.hibernate.dialect.SybaseDialect.getNameQualifierSupport.

Doc from org.hibernate.dialect.Dialect.getNameQualifierSupport.

By default interpret this based on DatabaseMetaData.

Returns:NameQualifierSupport

The NameQualifierSupport.

Annotations
@Override
getSqlTypeDescriptorOverrideback to summary
protected SqlTypeDescriptor getSqlTypeDescriptorOverride(int sqlCode)

Overrides org.hibernate.dialect.SybaseDialect.getSqlTypeDescriptorOverride.

Doc from org.hibernate.dialect.Dialect.getSqlTypeDescriptorOverride.

Returns the SqlTypeDescriptor that should be used to handle the given JDBC type code. Returns null if there is no override.

Parameters
sqlCode:int

A Types constant indicating the SQL column type

Returns:SqlTypeDescriptor

The SqlTypeDescriptor to use as an override, or null if there is no override.

Annotations
@Override
registerSybaseKeywordsback to summary
private void registerSybaseKeywords()
supportsCascadeDeleteback to summary
public boolean supportsCascadeDelete()

Overrides org.hibernate.dialect.Dialect.supportsCascadeDelete.

Doc from org.hibernate.dialect.Dialect.supportsCascadeDelete.

Does this dialect support cascaded delete on foreign key definitions?

Returns:boolean

true indicates that the dialect does support cascaded delete on foreign keys.

Annotations
@Override
supportsExpectedLobUsagePatternback to summary
public boolean supportsExpectedLobUsagePattern()

Overrides org.hibernate.dialect.Dialect.supportsExpectedLobUsagePattern.

Actually Sybase does not support LOB locators at al.

Returns:boolean

Doc from org.hibernate.dialect.Dialect.supportsExpectedLobUsagePattern.

false.

True if normal LOB usage patterns can be used with this driver; false if driver-specific hookiness needs to be applied.

Annotations
@Override
supportsLockTimeoutsback to summary
public boolean supportsLockTimeouts()

Overrides org.hibernate.dialect.Dialect.supportsLockTimeouts.

Doc from org.hibernate.dialect.Dialect.supportsLockTimeouts.

Informational metadata about whether this dialect is known to support specifying timeouts for requested lock acquisitions.

Returns:boolean

True is this dialect supports specifying lock timeouts.

Annotations
@Override
supportsPartitionByback to summary
public boolean supportsPartitionBy()

Overrides org.hibernate.dialect.AbstractTransactSQLDialect.supportsPartitionBy.

Doc from org.hibernate.dialect.Dialect.supportsPartitionBy.

Does the underlying database support partition by

Returns:boolean

boolean

Annotations
@Override