org.hibernate.dialect
Class SybaseDialect

java.lang.Object
  extended byorg.hibernate.dialect.Dialect
      extended byorg.hibernate.dialect.SybaseDialect
Direct Known Subclasses:
SQLServerDialect, Sybase11Dialect, SybaseAnywhereDialect

public class SybaseDialect
extends Dialect

An SQL dialect compatible with Sybase and MS SQL Server.

Author:
Gavin King

Field Summary
 
Fields inherited from class org.hibernate.dialect.Dialect
CLOSED_QUOTE, QUOTE
 
Constructor Summary
SybaseDialect()
           
 
Method Summary
 String appendIdentitySelectToInsert(String insertSQL)
          Append a clause to retrieve the generated identity value for the given INSERT statement.
 String appendLockHint(LockMode mode, String tableName)
          Method appendLockHint appends according to the given lock mode a lock hint behind the given table name, if this dialect needs this.
 boolean dropTemporaryTableAfterUse()
           
 String generateTemporaryTableName(String baseTableName)
           
 String getAddColumnString()
          The syntax used to add a column to a table (optional).
 String getCurrentTimestampSelectString()
           
 String getForUpdateString()
          Does this dialect support the FOR UPDATE syntax?
 String getIdentityColumnString()
           
 String getIdentitySelectString()
           
 String getNullColumnString()
          The keyword used to specify a nullable column.
 ResultSet getResultSet(CallableStatement ps)
           
 boolean isCurrentTimestampSelectStringCallable()
           
 boolean qualifyIndexName()
          Do we need to qualify index names with the schema name?
 int registerResultSetOutParameter(CallableStatement statement, int col)
           
 boolean supportsCurrentTimestampSelection()
           
 boolean supportsIdentityColumns()
          Does this dialect support identity column key generation?
 boolean supportsInsertSelectIdentity()
           
 boolean supportsTemporaryTables()
           
 
Methods inherited from class org.hibernate.dialect.Dialect
bindLimitParametersFirst, bindLimitParametersInReverseOrder, buildSQLExceptionConverter, closeQuote, createCaseFragment, createOuterJoinFragment, dropConstraints, forUpdateOfColumns, getAddForeignKeyConstraintString, getAddPrimaryKeyConstraintString, getCascadeConstraintsString, getCastTypeName, getColumnComment, getCreateSequenceString, getCreateSequenceStrings, getCreateTemporaryTablePostfix, getCreateTemporaryTableString, getCurrentTimestampSQLFunctionName, getDefaultProperties, getDialect, getDialect, getDropForeignKeyString, getDropSequenceString, getDropSequenceStrings, getForUpdateNowaitString, getForUpdateNowaitString, getForUpdateString, getForUpdateString, getFunctions, getHibernateTypeName, getHibernateTypeName, getIdentityColumnString, getIdentityInsertString, getIdentitySelectString, getKeywords, getLimitString, getLimitString, getLowercaseFunction, getMaxAliasLength, getNativeIdentifierGeneratorClass, getNoColumnsInsertString, getQuerySequencesString, getSelectClauseNullString, getSelectGUIDString, getSelectSequenceNextValString, getSequenceNextValString, getTableComment, getTableTypeString, getTypeName, getTypeName, getViolatedConstraintNameExtracter, hasAlterTable, hasDataTypeInIdentityColumn, hasSelfReferentialForeignKeyBug, openQuote, performTemporaryTableDDLInIsolation, quote, registerColumnType, registerColumnType, registerFunction, registerHibernateType, registerHibernateType, registerKeyword, supportsCascadeDelete, supportsColumnCheck, supportsCommentOn, supportsIfExistsAfterTableName, supportsIfExistsBeforeTableName, supportsLimit, supportsLimitOffset, supportsNotNullUnique, supportsOuterJoinForUpdate, supportsParametersInInsertSelect, supportsSequences, supportsTableCheck, 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

SybaseDialect

public SybaseDialect()
Method Detail

getAddColumnString

public String getAddColumnString()
Description copied from class: Dialect
The syntax used to add a column to a table (optional).

Overrides:
getAddColumnString in class Dialect

getNullColumnString

public String getNullColumnString()
Description copied from class: Dialect
The keyword used to specify a nullable column.

Overrides:
getNullColumnString in class Dialect
Returns:
String

qualifyIndexName

public boolean qualifyIndexName()
Description copied from class: Dialect
Do we need to qualify index names with the schema name?

Overrides:
qualifyIndexName in class Dialect
Returns:
boolean

getForUpdateString

public String getForUpdateString()
Description copied from class: Dialect
Does this dialect support the FOR UPDATE syntax?

Overrides:
getForUpdateString in class Dialect
Returns:
boolean

supportsIdentityColumns

public boolean supportsIdentityColumns()
Description copied from class: Dialect
Does this dialect support identity column key generation?

Overrides:
supportsIdentityColumns in class Dialect
Returns:
boolean

getIdentitySelectString

public String getIdentitySelectString()
Overrides:
getIdentitySelectString in class Dialect

getIdentityColumnString

public String getIdentityColumnString()
Overrides:
getIdentityColumnString in class Dialect

supportsInsertSelectIdentity

public boolean supportsInsertSelectIdentity()
Overrides:
supportsInsertSelectIdentity in class Dialect

appendIdentitySelectToInsert

public String appendIdentitySelectToInsert(String insertSQL)
Description copied from class: Dialect
Append a clause to retrieve the generated identity value for the given INSERT statement.

Overrides:
appendIdentitySelectToInsert in class Dialect

appendLockHint

public String appendLockHint(LockMode mode,
                             String tableName)
Description copied from class: Dialect
Method appendLockHint appends according to the given lock mode a lock hint behind the given table name, if this dialect needs this. MS SQL Server for example doesn't support the standard "select ... for update" syntax and use a special "select ... from TABLE as ALIAS with (updlock, rowlock) where ..." syntax instead.

Overrides:
appendLockHint in class Dialect
Parameters:
tableName - name of table to append lock hint
Returns:
String

author Helge Schulz


registerResultSetOutParameter

public int registerResultSetOutParameter(CallableStatement statement,
                                         int col)
                                  throws SQLException
Overrides:
registerResultSetOutParameter in class Dialect
Throws:
SQLException

getResultSet

public ResultSet getResultSet(CallableStatement ps)
                       throws SQLException
Overrides:
getResultSet in class Dialect
Throws:
SQLException

supportsCurrentTimestampSelection

public boolean supportsCurrentTimestampSelection()
Overrides:
supportsCurrentTimestampSelection in class Dialect

isCurrentTimestampSelectStringCallable

public boolean isCurrentTimestampSelectStringCallable()
Overrides:
isCurrentTimestampSelectStringCallable in class Dialect

getCurrentTimestampSelectString

public String getCurrentTimestampSelectString()
Overrides:
getCurrentTimestampSelectString in class Dialect

supportsTemporaryTables

public boolean supportsTemporaryTables()
Overrides:
supportsTemporaryTables in class Dialect

generateTemporaryTableName

public String generateTemporaryTableName(String baseTableName)
Overrides:
generateTemporaryTableName in class Dialect

dropTemporaryTableAfterUse

public boolean dropTemporaryTableAfterUse()
Overrides:
dropTemporaryTableAfterUse in class Dialect