Class SQLAnywherePlatform

  • All Implemented Interfaces:
    java.io.Serializable, java.lang.Cloneable, org.eclipse.persistence.internal.core.databaseaccess.CorePlatform<org.eclipse.persistence.internal.helper.ConversionManager>, org.eclipse.persistence.internal.databaseaccess.Platform

    public class SQLAnywherePlatform
    extends SybasePlatform
    Provides SQL Anywhere specific behaviour.
    See Also:
    Serialized Form
    Author:
    Markus KARG (markus-karg@users.sourceforge.net)
    • Field Summary

      • Fields inherited from class org.eclipse.persistence.internal.databaseaccess.DatabasePlatform

        batchWritingMechanism, castSizeForVarcharParameter, classTypes, cursorCode, DEFAULT_MAX_BATCH_WRITING_SIZE, DEFAULT_PARAMETERIZED_MAX_BATCH_WRITING_SIZE, driverName, driverSupportsNationalCharacterVarying, fieldTypes, IS_VALID_TIMEOUT, isCastRequired, maxBatchWritingSize, partitioningCallback, pingSQL, printInnerJoinInWhereClause, printOuterJoinInWhereClause, shouldBindAllParameters, shouldBindLiterals, shouldBindPartialParameters, shouldCacheAllStatements, shouldCreateIndicesOnForeignKeys, shouldForceBindAllParameters, shouldForceFieldNamesToUpperCase, shouldIgnoreCaseOnFieldComparisons, shouldOptimizeDataConversion, shouldTrimStrings, statementCacheSize, storedProcedureTerminationToken, stringBindingSize, structConverters, supportsAutoCommit, tableCreationSuffix, transactionIsolation, typeConverters, Types_NCLOB, Types_SQLXML, useJDBCStoredProcedureSyntax, useNationalCharacterVarying, useRownumFiltering, usesBatchWriting, usesByteArrayBinding, usesJDBCBatchWriting, usesNativeBatchWriting, usesNativeSQL, usesStreamsForBinding, usesStringBinding
      • Fields inherited from class org.eclipse.persistence.internal.databaseaccess.DatasourcePlatform

        conversionManager, dataTypesConvertedFromAClass, dataTypesConvertedToAClass, defaultNativeSequenceToTable, defaultSeqenceAtNextValue, defaultSequence, endDelimiter, platformOperators, sequences, sequencesLock, startDelimiter, supportsReturnGeneratedKeys, tableQualifier, timestampQuery
    • Method Summary

      All Methods Static Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      protected java.util.Hashtable buildFieldTypes()  
      ValueReadQuery buildSelectQueryForIdentity()
      INTERNAL: Build the identity query for native sequencing.
      static ExpressionOperator createConcatOperator()  
      static ExpressionOperator createCurrentDateOperator()  
      static ExpressionOperator createCurrentTimeOperator()  
      static ExpressionOperator createLocate2Operator()  
      static ExpressionOperator createLocateOperator()  
      java.lang.String getBatchBeginString()
      Used for batch writing and sp defs.
      java.lang.String getBatchDelimiterString()
      Used for batch writing and sp defs.
      java.lang.String getBatchEndString()
      Used for batch writing and sp defs.
      protected java.lang.String getCreateTempTableSqlPrefix()
      INTERNAL:
      java.lang.String getCreationOutputProcedureToken()  
      java.lang.String getInOutputProcedureToken()  
      java.lang.String getInputProcedureToken()
      Used for stored procedure creation: Prefix for INPUT parameters.
      int getMaxFieldNameSize()
      INTERNAL: returns the maximum number of characters that can be used in a field name on this platform.
      java.lang.String getOutputProcedureToken()  
      java.lang.String getProcedureArgumentString()
      Used for sp defs.
      java.lang.String getProcedureAsString()  
      java.lang.String getProcedureBeginString()  
      java.lang.String getProcedureCallHeader()
      Used for sp calls.
      java.lang.String getProcedureEndString()  
      java.lang.String getStoredProcedureParameterPrefix()  
      org.eclipse.persistence.internal.helper.DatabaseTable getTempTableForTable​(org.eclipse.persistence.internal.helper.DatabaseTable table)
      Used for sp calls.
      protected void initializePlatformOperators()
      Initialize any platform-specific operators
      boolean isSQLAnywhere()  
      boolean isSybase()  
      void printFieldIdentityClause​(java.io.Writer writer)
      Append the receiver's field 'identity' constraint clause to a writer.
      void printFieldNullClause​(java.io.Writer writer)
      Append the receiver's field 'NULL' constraint clause to a writer.
      boolean requiresProcedureBrackets()  
      boolean requiresProcedureCallBrackets()
      USed for sp calls.
      boolean requiresTypeNameToRegisterOutputParameter()
      INTERNAL: Indicates whether the version of CallableStatement.registerOutputParameter method that takes type name should be used.
      boolean shouldPrintInOutputTokenBeforeType()  
      boolean shouldPrintInputTokenAtStart()  
      boolean shouldPrintOutputTokenAtStart()  
      boolean shouldPrintOutputTokenBeforeType()  
      boolean shouldPrintStoredProcedureArgumentNameInCall()  
      boolean shouldPrintStoredProcedureVariablesAfterBeginString()  
      boolean supportsDeleteOnCascade()
      SQL Anywhere does support cascade on delete, unlike Sybase.
      boolean supportsIdentity()
      INTERNAL: Indicates whether the platform supports identity.
      boolean supportsLocalTempTables()  
      boolean supportsStoredFunctions()  
      • Methods inherited from class org.eclipse.persistence.internal.databaseaccess.DatabasePlatform

        addBatch, addStructConverter, allowBindingForSelectClause, allowsSizeInProcedureArguments, appendBoolean, appendLiteralToCall, appendLiteralToCallWithBinding, appendNumber, appendParameter, appendParameterInternal, appendString, autoCommit, beginTransaction, buildBatchCriteria, buildBatchCriteriaForComplexId, buildCallWithReturning, buildClassTypes, buildCreateIndex, buildCreateIndex, buildDropIndex, buildDropIndex, buildProcedureCallString, buildSequenceObjectAlterIncrementWriter, buildSequenceObjectCreationWriter, buildSequenceObjectDeletionWriter, canBatchWriteWithOptimisticLocking, canBuildCallWithReturning, checkTableExists, commitTransaction, computeMaxRowsForSQL, convertToDatabaseType, copyInto, createArray, createArray, createPlatformDefaultSequence, createStruct, createStruct, createStruct, dontBindUpdateAllQueryUsingTempTables, executeBatch, executeStoredProcedure, freeTemporaryObject, getAssignmentString, getBatchRowCountAssignString, getBatchRowCountDeclareString, getBatchRowCountReturnString, getBatchWritingMechanism, getCastSizeForVarcharParameter, getClassTypes, getConnection, getConnectionUserName, getConstraintDeletionString, getCreateDatabaseSchemaString, getCreateTempTableSqlBodyForTable, getCreateTempTableSqlSuffix, getCreateViewString, getCursorCode, getCustomModifyValueForCall, getDefaultSequenceTableName, getDriverSupportsNVarChar, getDropCascadeString, getDropDatabaseSchemaString, getFieldTypeDefinition, getFieldTypes, getFunctionCallHeader, getIdentifierQuoteCharacter, getIndexNamePrefix, getJDBCOuterJoinString, getJDBCType, getJDBCTypeForSetNull, getMaxBatchWritingSize, getMaxForeignKeyNameSize, getMaxIndexNameSize, getMaxUniqueKeyNameSize, getNoWaitString, getObjectFromResultSet, getParameterValueFromDatabaseCall, getParameterValueFromDatabaseCall, getPartitioningCallback, getPingSQL, getProcedureArgument, getProcedureArgument, getProcedureOptionList, getQualifiedName, getQualifiedSequenceTableName, getRefValue, getRefValue, getSelectForUpdateNoWaitString, getSelectForUpdateOfString, getSelectForUpdateWaitString, getSequenceCounterFieldName, getSequenceNameFieldName, getSequencePreallocationSize, getSequenceTableName, getStatementCacheSize, getStoredProcedureTerminationToken, getStringBindingSize, getStructConverters, getTableCreationSuffix, getTableExistsQuery, getTransactionIsolation, getTypeConverters, getUniqueConstraintDeletionString, getUseNationalCharacterVaryingTypeForString, getVPDClearIdentifierQuery, getVPDCreationFunctionString, getVPDCreationPolicyString, getVPDDeletionString, getVPDSetIdentifierQuery, hasPartitioningCallback, initialize, isAlterSequenceObjectSupported, isCastRequired, isDynamicSQLRequiredForFunctions, isForUpdateCompatibleWithDistinct, isInformixOuterJoin, isJDBCExecuteCompliant, isLobCompatibleWithDistinct, isLockTimeoutException, isNullAllowedInSelectClause, isRowCountOutputParameterRequired, isXDBDocument, minimumTimeIncrement, prepareBatchStatement, printFieldNotNullClause, printFieldTypeSize, printFieldTypeSize, printFieldUnique, printFieldUnique, printSQLSelectStatement, printStoredFunctionReturnKeyWord, printValuelist, printValuelist, registerOutputParameter, registerOutputParameter, requiresNamedPrimaryKeyConstraints, requiresTableInIndexDropDDL, requiresUniqueConstraintCreationOnTableCreate, retrieveFirstPrimaryKeyOrOne, rollbackTransaction, setBatchWritingMechanism, setCastSizeForVarcharParameter, setClassTypes, setCursorCode, setDriverName, setDriverSupportsNVarChar, setFieldTypes, setIsCastRequired, setMaxBatchWritingSize, setNullFromDatabaseField, setNullFromDatabaseField, setParameterValueInDatabaseCall, setParameterValueInDatabaseCall, setPartitioningCallback, setPingSQL, setPrintInnerJoinInWhereClause, setPrintOuterJoinInWhereClause, setSequenceCounterFieldName, setSequenceNameFieldName, setSequenceTableName, setShouldBindAllParameters, setShouldBindLiterals, setShouldBindPartialParameters, setShouldCacheAllStatements, setShouldCreateIndicesOnForeignKeys, setShouldForceBindAllParameters, setShouldForceFieldNamesToUpperCase, setShouldIgnoreCaseOnFieldComparisons, setShouldOptimizeDataConversion, setShouldTrimStrings, setShouldUseRownumFiltering, setStatementCacheSize, setStoredProcedureTerminationToken, setStringBindingSize, setSupportsAutoCommit, setTableCreationSuffix, setTransactionIsolation, setUseJDBCStoredProcedureSyntax, setUseNationalCharacterVaryingTypeForString, setUsesBatchWriting, setUsesByteArrayBinding, setUsesJDBCBatchWriting, setUsesNativeBatchWriting, setUsesNativeSQL, setUsesStreamsForBinding, setUsesStringBinding, shouldAlwaysUseTempStorageForModifyAll, shouldBindAllParameters, shouldBindLiterals, shouldBindPartialParameters, shouldCacheAllStatements, shouldCreateIndicesForPrimaryKeys, shouldCreateIndicesOnForeignKeys, shouldCreateIndicesOnUniqueKeys, shouldForceBindAllParameters, shouldForceFieldNamesToUpperCase, shouldIgnoreCaseOnFieldComparisons, shouldIgnoreException, shouldOptimizeDataConversion, shouldPrintAliasForUpdate, shouldPrintConstraintNameAfter, shouldPrintFieldIdentityClause, shouldPrintForUpdateClause, shouldPrintInnerJoinInWhereClause, shouldPrintOuterJoinInWhereClause, shouldTempTableSpecifyPrimaryKeys, shouldTrimStrings, shouldUseCustomModifyForCall, shouldUseGetSetNString, shouldUseRownumFiltering, supportsANSIInnerJoinSyntax, supportsAutoCommit, supportsAutoConversionToNumericForArithmeticOperations, supportsConnectionUserName, supportsCountDistinctWithMultipleFields, supportsForeignKeyConstraints, supportsIndexes, supportsIndividualTableLocking, supportsLockingQueriesWithMultipleTables, supportsNestingOuterJoins, supportsOrderByParameters, supportsOuterJoinsWithBrackets, supportsPrimaryKeyConstraint, supportsTempTables, supportsUniqueColumns, supportsUniqueKeyConstraints, supportsVPD, supportsWaitForUpdate, usesBatchWriting, usesByteArrayBinding, usesJDBCBatchWriting, usesNativeBatchWriting, usesNativeSQL, usesSequenceTable, usesStreamsForBinding, usesStringBinding, wasFailureCommunicationBased, writeAddColumnClause, writeAutoAssignmentSetClause, writeAutoJoinWhereClause, writeCleanUpTempTableSql, writeCreateTempTableSql, writeDeleteFromTargetTableUsingTempTableSql, writeFields, writeFieldsAutoClause, writeFieldsList, writeInsertIntoTableSql, writeJoinWhereClause, writeLOB, writeParameterMarker, writeTableCreationSuffix
      • Methods inherited from class org.eclipse.persistence.internal.databaseaccess.DatasourcePlatform

        addOperator, addSequence, addSequence, buildNativeCall, buildSelectQueryForIdentity, buildSelectQueryForSequenceObject, buildSelectQueryForSequenceObject, clone, convertObject, convertObject, createConnectionCustomizer, createExpressionFor, getConversionManager, getDataTypesConvertedFrom, getDataTypesConvertedTo, getDefaultNativeSequenceToTable, getDefaultSeqenceAtNextValue, getDefaultSequence, getDefaultSequenceToWrite, getDriverVersion, getEndDelimiter, getINClauseLimit, getOperator, getPlatformOperators, getSelectSequenceQuery, getSequence, getSequences, getSequencesToWrite, getStartDelimiter, getTableQualifier, getTimestampFromServer, getUpdateSequenceQuery, hasDefaultSequence, initializeDefaultQueries, isAccess, isAttunity, isCloudscape, isDB2, isDB2Z, isDBase, isDerby, isFirebird, isH2, isHANA, isHSQL, isInformix, isMaxDB, isMySQL, isODBC, isOracle, isOracle23, isOracle9, isPervasive, isPointBase, isPostgreSQL, isSQLServer, isSymfoware, isTimesTen, isTimesTen7, removeAllSequences, removeSequence, sequencesAfterCloneCleanup, setConversionManager, setDefaultNativeSequenceToTable, setDefaultSeqenceAtNextValue, setDefaultSequence, setEndDelimiter, setSelectSequenceNumberQuery, setSequencePreallocationSize, setSequences, setStartDelimiter, setSupportsReturnGeneratedKeys, setTableQualifier, setTimestampQuery, setUpdateSequenceQuery, shouldNativeSequenceUseTransaction, shouldPrepare, shouldSelectDistinctIncludeOrderBy, shouldSelectIncludeOrderBy, supportsNativeSequenceNumbers, supportsReturnGeneratedKeys, supportsSequenceObjects, toString, usesPlatformDefaultSequence
      • Methods inherited from class java.lang.Object

        equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
    • Constructor Detail

      • SQLAnywherePlatform

        public SQLAnywherePlatform()
    • Method Detail

      • createCurrentDateOperator

        public static ExpressionOperator createCurrentDateOperator()
      • createCurrentTimeOperator

        public static ExpressionOperator createCurrentTimeOperator()
      • getInputProcedureToken

        public java.lang.String getInputProcedureToken()
        Used for stored procedure creation: Prefix for INPUT parameters. Not required on most platforms.
        Overrides:
        getInputProcedureToken in class org.eclipse.persistence.internal.databaseaccess.DatabasePlatform
      • getMaxFieldNameSize

        public int getMaxFieldNameSize()
        Description copied from class: SybasePlatform
        INTERNAL: returns the maximum number of characters that can be used in a field name on this platform.
        Overrides:
        getMaxFieldNameSize in class SybasePlatform
      • getProcedureAsString

        public java.lang.String getProcedureAsString()
        Overrides:
        getProcedureAsString in class org.eclipse.persistence.internal.databaseaccess.DatabasePlatform
      • getProcedureBeginString

        public java.lang.String getProcedureBeginString()
        Overrides:
        getProcedureBeginString in class org.eclipse.persistence.internal.databaseaccess.DatabasePlatform
      • getProcedureEndString

        public java.lang.String getProcedureEndString()
        Overrides:
        getProcedureEndString in class org.eclipse.persistence.internal.databaseaccess.DatabasePlatform
      • getBatchBeginString

        public java.lang.String getBatchBeginString()
        Used for batch writing and sp defs.
        Overrides:
        getBatchBeginString in class org.eclipse.persistence.internal.databaseaccess.DatabasePlatform
      • getBatchEndString

        public java.lang.String getBatchEndString()
        Used for batch writing and sp defs.
        Overrides:
        getBatchEndString in class org.eclipse.persistence.internal.databaseaccess.DatabasePlatform
      • getTempTableForTable

        public org.eclipse.persistence.internal.helper.DatabaseTable getTempTableForTable​(org.eclipse.persistence.internal.helper.DatabaseTable table)
        Used for sp calls.
        Overrides:
        getTempTableForTable in class SybasePlatform
      • isSQLAnywhere

        public boolean isSQLAnywhere()
        Specified by:
        isSQLAnywhere in interface org.eclipse.persistence.internal.databaseaccess.Platform
        Overrides:
        isSQLAnywhere in class org.eclipse.persistence.internal.databaseaccess.DatasourcePlatform
      • isSybase

        public boolean isSybase()
        Specified by:
        isSybase in interface org.eclipse.persistence.internal.databaseaccess.Platform
        Overrides:
        isSybase in class SybasePlatform
      • requiresProcedureBrackets

        public boolean requiresProcedureBrackets()
        Overrides:
        requiresProcedureBrackets in class org.eclipse.persistence.internal.databaseaccess.DatabasePlatform
      • requiresTypeNameToRegisterOutputParameter

        public boolean requiresTypeNameToRegisterOutputParameter()
        INTERNAL: Indicates whether the version of CallableStatement.registerOutputParameter method that takes type name should be used.
        Overrides:
        requiresTypeNameToRegisterOutputParameter in class SybasePlatform
      • shouldPrintInputTokenAtStart

        public boolean shouldPrintInputTokenAtStart()
        Overrides:
        shouldPrintInputTokenAtStart in class org.eclipse.persistence.internal.databaseaccess.DatabasePlatform
      • shouldPrintOutputTokenAtStart

        public boolean shouldPrintOutputTokenAtStart()
        Overrides:
        shouldPrintOutputTokenAtStart in class org.eclipse.persistence.internal.databaseaccess.DatabasePlatform
      • shouldPrintStoredProcedureArgumentNameInCall

        public boolean shouldPrintStoredProcedureArgumentNameInCall()
        Overrides:
        shouldPrintStoredProcedureArgumentNameInCall in class org.eclipse.persistence.internal.databaseaccess.DatabasePlatform
      • shouldPrintStoredProcedureVariablesAfterBeginString

        public boolean shouldPrintStoredProcedureVariablesAfterBeginString()
        Overrides:
        shouldPrintStoredProcedureVariablesAfterBeginString in class org.eclipse.persistence.internal.databaseaccess.DatabasePlatform
      • supportsIdentity

        public boolean supportsIdentity()
        Description copied from class: SybasePlatform
        INTERNAL: Indicates whether the platform supports identity. Sybase does through IDENTITY field types. This method is to be used *ONLY* by sequencing classes
        Overrides:
        supportsIdentity in class SybasePlatform
      • supportsLocalTempTables

        public boolean supportsLocalTempTables()
        Overrides:
        supportsLocalTempTables in class org.eclipse.persistence.internal.databaseaccess.DatabasePlatform
      • supportsStoredFunctions

        public boolean supportsStoredFunctions()
        Overrides:
        supportsStoredFunctions in class org.eclipse.persistence.internal.databaseaccess.DatabasePlatform
      • supportsDeleteOnCascade

        public boolean supportsDeleteOnCascade()
        SQL Anywhere does support cascade on delete, unlike Sybase.
        Overrides:
        supportsDeleteOnCascade in class SybasePlatform