Class Oracle8Platform
java.lang.Object
org.eclipse.persistence.internal.databaseaccess.DatasourcePlatform
org.eclipse.persistence.internal.databaseaccess.DatabasePlatform
org.eclipse.persistence.platform.database.DatabasePlatform
org.eclipse.persistence.platform.database.OraclePlatform
org.eclipse.persistence.platform.database.oracle.Oracle8Platform
- All Implemented Interfaces:
Serializable
,Cloneable
,CorePlatform<ConversionManager>
,Platform
- Direct Known Subclasses:
Oracle9Platform
Purpose: Supports certain new Oracle 8 data types, and usage of certain Oracle JDBC specific APIs.
Supports Oracle thin JDBC driver LOB >4k binding workaround.
Creates BLOB and CLOB type for byte[] and char[] for table creation.
Supports object-relational data-type creation.
- See Also:
-
Field Summary
Modifier and TypeFieldDescriptionprotected int
The LOB value limits when the Locator is required for the writingprotected boolean
Locator is required for Oracle thin driver to write LOB value exceeds the limitsFields inherited from class org.eclipse.persistence.platform.database.OraclePlatform
BRACKET_END, END_FROM, END_FROM_ID, FROM, FROM_ID, HINT_END, HINT_START, LOCK_END, LOCK_START_PREFIX, LOCK_START_PREFIX_WHERE, LOCK_START_SUFFIX, MAX_ROW, MIN_ROW, ORDER_BY_ID, SELECT, SELECT_ID_PREFIX, SELECT_ID_SUFFIX, shouldPrintForUpdateClause, supportsIdentity, vpdClearIdentifierQuery, vpdSetIdentifierQuery
Fields inherited from class org.eclipse.persistence.platform.database.DatabasePlatform
DEFAULT_VARCHAR_SIZE
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, 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, uuidQuery
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionprotected Hashtable
<Class<?>, FieldTypeDefinition> INTERNAL:void
INTERNAL: Allow for conversion from the Oralce type to the Java type.createArray
(String elementDataTypeName, Object[] elements, Connection connection) INTERNAL: Platforms that support java.sql.Array may override this method.createStruct
(String structTypeName, Object[] attributes, Connection connection) INTERNAL: Platforms that support java.sql.Struct may override this method.void
freeTemporaryObject
(Object value) INTERNAL: Used by Oracle platforms during reading of ResultSet to free temporary LOBs.getConnection
(AbstractSession session, Connection connection) INTERNAL: This method is used to unwrap the oracle connection wrapped by the application server.getCustomModifyValueForCall
(Call call, Object value, DatabaseField field, boolean shouldBind) INTERNAL Used by SQLCall.translate(..) Typically there is no field translation (and this is default implementation).int
PUBLIC: Return the BLOB/CLOB value limits on thin driver.getRefValue
(Ref ref, Connection connection) INTERNAL: Overrides DatabasePlatform method.protected boolean
INTERNAL: Used in writeLOB method only to identify a BLOBprotected boolean
INTERNAL: Used in writeLOB method only to identify a CLOBboolean
INTERNAL: Indicates whether app.protected boolean
lobValueExceedsLimit
(Object value) INTERNAL: Return if the LOB value size is larger than the limit, i.e.void
setLobValueLimits
(int lobValueLimits) PUBLIC: Set the BLOB/CLOB value limits on thin driver.void
setShouldUseLocatorForLOBWrite
(boolean usesLocatorForLOBWrite) PUBLIC: Set if the locator is required for the LOB write.boolean
INTERNAL Used by SQLCall.appendModify(..) If the field should be passed to customModifyInDatabaseCall, retun true, otherwise false.boolean
PUBLIC: Return if the locator is required for the LOB write.void
writeLOB
(DatabaseField field, Object value, ResultSet resultSet, AbstractSession session) INTERNAL: Write LOB value - works on Oracle 10 and newerMethods inherited from class org.eclipse.persistence.platform.database.OraclePlatform
allowsSizeInProcedureArguments, appendByteArray, appendCalendar, appendDate, appendTime, appendTimestamp, buildCallWithReturning, buildFirstRowsHint, buildSelectQueryForIdentity, buildSelectQueryForSequenceObject, canBuildCallWithReturning, canUnwrapOracleConnection, checkTableExists, clearOracleConnectionCache, createExpressionFor, exceptOperator, getAssignmentString, getBatchBeginString, getBatchEndString, getBatchRowCountAssignString, getBatchRowCountDeclareString, getBatchRowCountReturnString, getDeclareBeginString, getDropCascadeString, getDropDatabaseSchemaString, getINClauseLimit, getMaxFieldNameSize, getNativeTableInfo, getObjectFromResultSet, getProcedureArgument, getProcedureCallHeader, getProcedureCallTail, getSelectForUpdateString, getSelectForUpdateWaitString, getStoredProcedureParameterPrefix, getSystemChangeNumberQuery, getTableExistsQuery, getTimestampQuery, getVPDClearIdentifierQuery, getVPDCreationFunctionString, getVPDCreationPolicyString, getVPDDeletionString, getVPDSetIdentifierQuery, initializeConnectionData, initializePlatformOperators, isAlterSequenceObjectSupported, isForUpdateCompatibleWithDistinct, isLobCompatibleWithDistinct, isLockTimeoutException, isOracle, isRowCountOutputParameterRequired, logOperator, maximumNumericValues, minimumNumericValues, operatorLocate, operatorLocate2, operatorOuterJoin, oracleDateName, printFieldNullClause, printSQLSelectStatement, regexpOperator, serverTimestampString, setSupportsIdentity, shouldPrintForUpdateClause, shouldPrintStoredProcedureArgumentNameInCall, shouldUseJDBCOuterJoinSyntax, supportsAutoConversionToNumericForArithmeticOperations, supportsIdentity, supportsSelectForUpdateNoWait, supportsSequenceObjects, supportsStoredFunctions, supportsVPD, supportsWaitForUpdate, unwrapOracleConnection, useJDBCStoredProcedureSyntax, wasFailureCommunicationBased
Methods inherited from class org.eclipse.persistence.internal.databaseaccess.DatabasePlatform
addBatch, addStructConverter, allowBindingForSelectClause, appendBoolean, appendLiteralToCall, appendLiteralToCallWithBinding, appendNumber, appendParameter, appendParameterInternal, appendString, autoCommit, beginTransaction, buildBatchCriteria, buildBatchCriteriaForComplexId, buildClassTypes, buildCreateIndex, buildCreateIndex, buildDropIndex, buildDropIndex, buildProcedureCallString, buildSequenceObjectAlterIncrementWriter, buildSequenceObjectCreationWriter, buildSequenceObjectDeletionWriter, canBatchWriteWithOptimisticLocking, commitTransaction, computeMaxRowsForSQL, convertToDatabaseType, createArray, createPlatformDefaultSequence, createStruct, createStruct, dontBindUpdateAllQueryUsingTempTables, executeBatch, executeStoredProcedure, getBatchDelimiterString, getBatchWritingMechanism, getCastSizeForVarcharParameter, getClassTypes, getConnectionUserName, getConstraintDeletionString, getCreateDatabaseSchemaString, getCreateTempTableSqlBodyForTable, getCreateTempTableSqlPrefix, getCreateTempTableSqlSuffix, getCreateViewString, getCreationInOutputProcedureToken, getCreationOutputProcedureToken, getCursorCode, getDefaultSequenceTableName, getDriverSupportsNVarChar, getFieldTypeDefinition, getFieldTypes, getFunctionCallHeader, getIndexNamePrefix, getInOutputProcedureToken, getInputProcedureToken, getJDBCOuterJoinString, getJDBCType, getJDBCType, getJDBCTypeForSetNull, getJdbcTypeName, getJsonPlatform, getMaxBatchWritingSize, getMaxForeignKeyNameSize, getMaxIndexNameSize, getMaxUniqueKeyNameSize, getNoWaitString, getOutputProcedureToken, getParameterValueFromDatabaseCall, getParameterValueFromDatabaseCall, getPartitioningCallback, getPingSQL, getProcedureArgumentString, getProcedureAsString, getProcedureBeginString, getProcedureEndString, getProcedureOptionList, getQualifiedName, getQualifiedSequenceTableName, getRefValue, getSelectForUpdateNoWaitString, getSelectForUpdateOfString, getSequenceCounterFieldName, getSequenceNameFieldName, getSequencePreallocationSize, getSequenceTableName, getStatementCacheSize, getStoredProcedureTerminationToken, getStringBindingSize, getStructConverters, getTableCreationSuffix, getTempTableForTable, getTransactionIsolation, getTypeConverters, getUniqueConstraintDeletionString, getUseNationalCharacterVaryingTypeForString, hasPartitioningCallback, initialize, isCastRequired, isDynamicSQLRequiredForFunctions, isInformixOuterJoin, isJDBCExecuteCompliant, isNullAllowedInSelectClause, isOutputAllowWithResultSet, isXDBDocument, minimumTimeIncrement, prepareBatchStatement, printFieldIdentityClause, printFieldNotNullClause, printFieldTypeSize, printFieldTypeSize, printFieldUnique, printFieldUnique, printStoredFunctionReturnKeyWord, printValuelist, printValuelist, registerOutputParameter, registerOutputParameter, registerOutputParameter, registerOutputParameter, requiresNamedPrimaryKeyConstraints, requiresProcedureBrackets, requiresProcedureCallBrackets, requiresProcedureCallOuputToken, requiresTableInIndexDropDDL, requiresTypeNameToRegisterOutputParameter, 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, shouldPrintInnerJoinInWhereClause, shouldPrintInOutputTokenBeforeType, shouldPrintInputTokenAtStart, shouldPrintLockingClauseAfterWhereClause, shouldPrintOuterJoinInWhereClause, shouldPrintOutputTokenAtStart, shouldPrintOutputTokenBeforeType, shouldPrintStoredProcedureVariablesAfterBeginString, shouldTempTableSpecifyPrimaryKeys, shouldTrimStrings, shouldUseGetSetNString, shouldUseRownumFiltering, supportsANSIInnerJoinSyntax, supportsAutoCommit, supportsConnectionUserName, supportsCountDistinctWithMultipleFields, supportsDeleteOnCascade, supportsForeignKeyConstraints, supportsGlobalTempTables, supportsIndexes, supportsIndividualTableLocking, supportsLocalTempTables, supportsLockingQueriesWithMultipleTables, supportsNestingOuterJoins, supportsOrderByParameters, supportsOuterJoinsWithBrackets, supportsPrimaryKeyConstraint, supportsTempTables, supportsUniqueColumns, supportsUniqueKeyConstraints, usesBatchWriting, usesByteArrayBinding, usesJDBCBatchWriting, usesNativeBatchWriting, usesNativeSQL, usesSequenceTable, usesStreamsForBinding, usesStringBinding, writeAddColumnClause, writeAutoAssignmentSetClause, writeAutoJoinWhereClause, writeCleanUpTempTableSql, writeCreateTempTableSql, writeDeleteFromTargetTableUsingTempTableSql, writeFields, writeFieldsAutoClause, writeFieldsList, writeInsertIntoTableSql, writeJoinWhereClause, writeParameterMarker, writeTableCreationSuffix, writeUpdateOriginalFromTempTableSql
Methods inherited from class org.eclipse.persistence.internal.databaseaccess.DatasourcePlatform
addOperator, addSequence, addSequence, buildNativeCall, buildSelectQueryForIdentity, buildSelectQueryForSequenceObject, clone, convertObject, createConnectionCustomizer, getConversionManager, getDataTypesConvertedFrom, getDataTypesConvertedTo, getDefaultNativeSequenceToTable, getDefaultSeqenceAtNextValue, getDefaultSequence, getDefaultSequenceToWrite, getDriverVersion, getEndDelimiter, getOperator, getPlatformOperators, getSelectSequenceQuery, getSequence, getSequences, getSequencesToWrite, getStartDelimiter, getTableQualifier, getTimestampFromServer, getUpdateSequenceQuery, getUUIDQuery, hasDefaultSequence, initializeDefaultQueries, initIdentitySequences, isAccess, isAttunity, isCloudscape, isDB2, isDB2Z, isDBase, isDerby, isFirebird, isH2, isHANA, isHSQL, isInformix, isMariaDB, isMaxDB, isMySQL, isODBC, isOracle12, isOracle23, isOracle9, isPervasive, isPointBase, isPostgreSQL, isSQLAnywhere, isSQLServer, isSybase, isSymfoware, isTimesTen, isTimesTen7, removeAllSequences, removeIdentitySequences, removeSequence, sequencesAfterCloneCleanup, setConversionManager, setDefaultNativeSequenceToTable, setDefaultSeqenceAtNextValue, setDefaultSequence, setEndDelimiter, setSelectSequenceNumberQuery, setSequencePreallocationSize, setSequences, setStartDelimiter, setSupportsReturnGeneratedKeys, setTableQualifier, setTimestampQuery, setUpdateSequenceQuery, setUUIDQuery, shouldNativeSequenceUseTransaction, shouldPrepare, shouldSelectDistinctIncludeOrderBy, shouldSelectIncludeOrderBy, supportsNativeSequenceNumbers, supportsReturnGeneratedKeys, toString, usesPlatformDefaultSequence
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Methods inherited from interface org.eclipse.persistence.internal.databaseaccess.Platform
connectionProperties
-
Field Details
-
usesLocatorForLOBWrite
protected boolean usesLocatorForLOBWriteLocator is required for Oracle thin driver to write LOB value exceeds the limits -
lobValueLimits
protected int lobValueLimitsThe LOB value limits when the Locator is required for the writing
-
-
Constructor Details
-
Oracle8Platform
public Oracle8Platform()Default constructor.
-
-
Method Details
-
buildFieldTypes
INTERNAL:- Overrides:
buildFieldTypes
in classOraclePlatform
-
copyInto
INTERNAL: Allow for conversion from the Oralce type to the Java type.- Specified by:
copyInto
in interfacePlatform
- Overrides:
copyInto
in classDatabasePlatform
-
lobValueExceedsLimit
INTERNAL: Return if the LOB value size is larger than the limit, i.e. 4k. -
getConnection
INTERNAL: This method is used to unwrap the oracle connection wrapped by the application server. TopLink needs this unwrapped connection for certain Oracle Specific support. (ie TIMESTAMPTZ, LOB) This is added as a workaround for bug 4565190- Overrides:
getConnection
in classDatabasePlatform
-
getCustomModifyValueForCall
public Object getCustomModifyValueForCall(Call call, Object value, DatabaseField field, boolean shouldBind) INTERNAL Used by SQLCall.translate(..) Typically there is no field translation (and this is default implementation). However on different platforms (Oracle) there are cases such that the values for binding and appending may be different (BLOB, CLOB). In these special cases the method returns a wrapper object which knows whether it should be bound or appended and knows how to do that.- Specified by:
getCustomModifyValueForCall
in interfacePlatform
- Overrides:
getCustomModifyValueForCall
in classDatabasePlatform
-
shouldUseCustomModifyForCall
INTERNAL Used by SQLCall.appendModify(..) If the field should be passed to customModifyInDatabaseCall, retun true, otherwise false. Methods shouldCustomModifyInDatabaseCall and customModifyInDatabaseCall should be kept in sync: shouldCustomModifyInDatabaseCall should return true if and only if the field is handled by customModifyInDatabaseCall.- Specified by:
shouldUseCustomModifyForCall
in interfacePlatform
- Overrides:
shouldUseCustomModifyForCall
in classDatabasePlatform
-
writeLOB
public void writeLOB(DatabaseField field, Object value, ResultSet resultSet, AbstractSession session) throws SQLException INTERNAL: Write LOB value - works on Oracle 10 and newer- Overrides:
writeLOB
in classDatabasePlatform
- Throws:
SQLException
-
isBlob
INTERNAL: Used in writeLOB method only to identify a BLOB -
isClob
INTERNAL: Used in writeLOB method only to identify a CLOB -
isNativeConnectionRequiredForLobLocator
public boolean isNativeConnectionRequiredForLobLocator()INTERNAL: Indicates whether app. server should unwrap connection to use lob locator.- Overrides:
isNativeConnectionRequiredForLobLocator
in classOraclePlatform
-
setShouldUseLocatorForLOBWrite
public void setShouldUseLocatorForLOBWrite(boolean usesLocatorForLOBWrite) PUBLIC: Set if the locator is required for the LOB write. The default is true. For Oracle thin driver, the locator is recommended for large size ( >4k for Oracle8, >5.9K for Oracle9) BLOB/CLOB value write. -
shouldUseLocatorForLOBWrite
public boolean shouldUseLocatorForLOBWrite()PUBLIC: Return if the locator is required for the LOB write. The default is true. For Oracle thin driver, the locator is recommended for large size ( >4k for Oracle8, >5.9K for Oracle9) BLOB/CLOB value write. -
getLobValueLimits
public int getLobValueLimits()PUBLIC: Return the BLOB/CLOB value limits on thin driver. The default value is 0. If usesLocatorForLOBWrite is true, locator will be used in case the lob's size is larger than lobValueLimit. -
setLobValueLimits
public void setLobValueLimits(int lobValueLimits) PUBLIC: Set the BLOB/CLOB value limits on thin driver. The default value is 0. If usesLocatorForLOBWrite is true, locator will be used in case the lob's size is larger than lobValueLimit. -
createArray
public Array createArray(String elementDataTypeName, Object[] elements, Connection connection) throws SQLException INTERNAL: Platforms that support java.sql.Array may override this method.- Overrides:
createArray
in classDatabasePlatform
- Returns:
- Array
- Throws:
SQLException
-
createStruct
public Struct createStruct(String structTypeName, Object[] attributes, Connection connection) throws SQLException INTERNAL: Platforms that support java.sql.Struct may override this method.- Overrides:
createStruct
in classDatabasePlatform
- Returns:
- Struct
- Throws:
SQLException
-
getRefValue
INTERNAL: Overrides DatabasePlatform method.- Overrides:
getRefValue
in classDatabasePlatform
- Returns:
- String
- Throws:
SQLException
-
freeTemporaryObject
INTERNAL: Used by Oracle platforms during reading of ResultSet to free temporary LOBs.- Overrides:
freeTemporaryObject
in classDatabasePlatform
- Throws:
SQLException
-