Class Informix11Platform
- 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.InformixPlatform
-
- org.eclipse.persistence.platform.database.Informix11Platform
-
- 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 Informix11Platform extends InformixPlatform
AnInformixPlatformthat fixes many EclipseLink bugs related to Informix support.
-
-
Field Summary
-
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, 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
-
-
Constructor Summary
Constructors Constructor Description Informix11Platform()Creates a newInformix11Platform.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected voidappendBoolean(java.lang.Boolean booleanValue, java.io.Writer writer)Fixes EclipseLink bug 401746 by writing out either't'or'f'—with single quotes— instead of1or0.protected ExpressionOperatorcurrentDateOperator()Fixes EclipseLink bug 402953 by returning the result of running the following code:ExpressionOperator.simpleFunctionNoParentheses(ExpressionOperator.CurrentDate, "CURRENT YEAR TO DAY");protected ExpressionOperatorcurrentTimeOperator()Fixes EclipseLink bug 402953 by returning the result of running the following code:ExpressionOperator.simpleFunctionNoParentheses(ExpressionOperator.CurrentDate, "CURRENT YEAR TO FRACTION(3)");protected ExpressionOperatordistinctOperator()Fixes EclipseLink bug 402600 by making sure that theDistinctExpressionOperatoris set to print asDISTINCT (no parentheses, one trailing space), and fixesbooleandontBindUpdateAllQueryUsingTempTables()Returnstruewhen invoked to indicate that parameter binding must not be used when working with temporary tables as part of anUPDATEquery.protected java.lang.StringgetCreateTempTableSqlPrefix()ReturnsCREATE TEMP TABLEwhen invoked, per the Informix 11.70 Information Center documentation.protected java.lang.StringgetCreateTempTableSqlSuffix()ReturnsWITH NO LOGwhen invoked, per the Informix 11.70 Information Center documentation, since transactions are not needed on temp tables for the purposes for which EclipseLink uses them.java.lang.ObjectgetObjectFromResultSet(java.sql.ResultSet resultSet, int columnNumber, int jdbcType, org.eclipse.persistence.internal.sessions.AbstractSession session)OverridesDatabasePlatform.getObjectFromResultSet(ResultSet, int, int, AbstractSession)so that if the suppliedjdbcTypeis equal toTypes.LONGVARCHAR, then theResultSet.getString(int)method (instead of theResultSet.getObject(int)method) is used to fetch the "raw" value of the column indicated by the suppliedcolumnNumberfrom the suppliedResultSet.org.eclipse.persistence.internal.helper.DatabaseTablegetTempTableForTable(org.eclipse.persistence.internal.helper.DatabaseTable table)Overrides the superclass implementation to return a newDatabaseTablewith no DatabaseTable.getTableQualifier().protected voidinitializePlatformOperators()Fixes EclipseLink bug 402600 by making sure that theDistinctExpressionOperatoris set to print asDISTINCT (no parentheses, one trailing space), and fixes EclipseLink bug 402953 by adding platform operators for current date and current time.booleanisInformixOuterJoin()Overrides the default behavior to returnfalse, indicating that ANSIOUTER JOINsyntax should be used, since all modern versions of Informix support it.booleanshouldAlwaysUseTempStorageForModifyAll()Returnstruewhen invoked to force Informix to use temporary storage when constructing bulkUPDATEstatements.booleansupportsLocalTempTables()Returnstruewhen invoked to indicate that Informix does indeed support local temporary tables.voidwriteUpdateOriginalFromTempTableSql(java.io.Writer writer, org.eclipse.persistence.internal.helper.DatabaseTable table, java.util.Collection pkFields, java.util.Collection assignedFields)OverridesDatabasePlatform.writeUpdateOriginalFromTempTableSql(Writer, DatabaseTable, Collection, Collection)to ensure that aSETclause that is supposed to set a value for only one column does not wrap that column name in parentheses.-
Methods inherited from class org.eclipse.persistence.platform.database.InformixPlatform
appendCalendar, appendDate, appendInformixCalendar, appendInformixTimestamp, appendTime, appendTimestamp, buildFieldTypes, buildSelectQueryForIdentity, buildSelectQueryForSequenceObject, getMaxFieldNameSize, getSelectForUpdateString, initializeConnectionData, isAlterSequenceObjectSupported, isInformix, maximumNumericValues, minimumNumericValues, printFieldIdentityClause, printFieldTypeSize, requiresProcedureCallBrackets, shouldPrintConstraintNameAfter, shouldSelectIncludeOrderBy, supportsIdentity, supportsSequenceObjects
-
Methods inherited from class org.eclipse.persistence.internal.databaseaccess.DatabasePlatform
addBatch, addStructConverter, allowBindingForSelectClause, allowsSizeInProcedureArguments, appendByteArray, 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, executeBatch, executeStoredProcedure, freeTemporaryObject, getAssignmentString, getBatchBeginString, getBatchDelimiterString, getBatchEndString, getBatchRowCountAssignString, getBatchRowCountDeclareString, getBatchRowCountReturnString, getBatchWritingMechanism, getCastSizeForVarcharParameter, getClassTypes, getConnection, getConnectionUserName, getConstraintDeletionString, getCreateDatabaseSchemaString, getCreateTempTableSqlBodyForTable, getCreateViewString, getCreationInOutputProcedureToken, getCreationOutputProcedureToken, getCursorCode, getCustomModifyValueForCall, getDefaultSequenceTableName, getDriverSupportsNVarChar, getDropCascadeString, getDropDatabaseSchemaString, getFieldTypeDefinition, getFieldTypes, getFunctionCallHeader, getIdentifierQuoteCharacter, getIndexNamePrefix, getInOutputProcedureToken, getInputProcedureToken, getJDBCOuterJoinString, getJDBCType, getJDBCType, getJDBCTypeForSetNull, getJdbcTypeName, getMaxBatchWritingSize, getMaxForeignKeyNameSize, getMaxIndexNameSize, getMaxUniqueKeyNameSize, getNoWaitString, getOutputProcedureToken, getParameterValueFromDatabaseCall, getParameterValueFromDatabaseCall, getPartitioningCallback, getPingSQL, getProcedureArgument, getProcedureArgument, getProcedureArgumentString, getProcedureAsString, getProcedureBeginString, getProcedureCallHeader, getProcedureCallTail, getProcedureEndString, getProcedureOptionList, getQualifiedName, getQualifiedSequenceTableName, getRefValue, getRefValue, getSelectForUpdateNoWaitString, getSelectForUpdateOfString, getSelectForUpdateWaitString, getSequenceCounterFieldName, getSequenceNameFieldName, getSequencePreallocationSize, getSequenceTableName, getStatementCacheSize, getStoredProcedureParameterPrefix, getStoredProcedureTerminationToken, getStringBindingSize, getStructConverters, getTableCreationSuffix, getTableExistsQuery, getTransactionIsolation, getTypeConverters, getUniqueConstraintDeletionString, getUseNationalCharacterVaryingTypeForString, getVPDClearIdentifierQuery, getVPDCreationFunctionString, getVPDCreationPolicyString, getVPDDeletionString, getVPDSetIdentifierQuery, hasPartitioningCallback, initialize, isCastRequired, isDynamicSQLRequiredForFunctions, isForUpdateCompatibleWithDistinct, isJDBCExecuteCompliant, isLobCompatibleWithDistinct, isLockTimeoutException, isNullAllowedInSelectClause, isOutputAllowWithResultSet, isRowCountOutputParameterRequired, isXDBDocument, minimumTimeIncrement, prepareBatchStatement, printFieldNotNullClause, printFieldNullClause, printFieldTypeSize, printFieldUnique, printFieldUnique, printSQLSelectStatement, printStoredFunctionReturnKeyWord, printValuelist, printValuelist, registerOutputParameter, registerOutputParameter, registerOutputParameter, registerOutputParameter, requiresNamedPrimaryKeyConstraints, requiresProcedureBrackets, 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, shouldBindAllParameters, shouldBindLiterals, shouldBindPartialParameters, shouldCacheAllStatements, shouldCreateIndicesForPrimaryKeys, shouldCreateIndicesOnForeignKeys, shouldCreateIndicesOnUniqueKeys, shouldForceBindAllParameters, shouldForceFieldNamesToUpperCase, shouldIgnoreCaseOnFieldComparisons, shouldIgnoreException, shouldOptimizeDataConversion, shouldPrintAliasForUpdate, shouldPrintFieldIdentityClause, shouldPrintForUpdateClause, shouldPrintInnerJoinInWhereClause, shouldPrintInOutputTokenBeforeType, shouldPrintInputTokenAtStart, shouldPrintLockingClauseAfterWhereClause, shouldPrintOuterJoinInWhereClause, shouldPrintOutputTokenAtStart, shouldPrintOutputTokenBeforeType, shouldPrintStoredProcedureArgumentNameInCall, shouldPrintStoredProcedureVariablesAfterBeginString, shouldTempTableSpecifyPrimaryKeys, shouldTrimStrings, shouldUseCustomModifyForCall, shouldUseGetSetNString, shouldUseJDBCOuterJoinSyntax, shouldUseRownumFiltering, supportsANSIInnerJoinSyntax, supportsAutoCommit, supportsAutoConversionToNumericForArithmeticOperations, supportsConnectionUserName, supportsCountDistinctWithMultipleFields, supportsDeleteOnCascade, supportsForeignKeyConstraints, supportsGlobalTempTables, supportsIndexes, supportsIndividualTableLocking, supportsLockingQueriesWithMultipleTables, supportsNestingOuterJoins, supportsOrderByParameters, supportsOuterJoinsWithBrackets, supportsPrimaryKeyConstraint, supportsStoredFunctions, 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, clone, convertObject, convertObject, createConnectionCustomizer, createExpressionFor, getConversionManager, getDataTypesConvertedFrom, getDataTypesConvertedTo, getDefaultNativeSequenceToTable, getDefaultSeqenceAtNextValue, getDefaultSequence, getDefaultSequenceToWrite, getDriverVersion, getEndDelimiter, getINClauseLimit, getOperator, getPlatformOperators, getSelectSequenceQuery, getSequence, getSequences, getSequencesToWrite, getStartDelimiter, getTableQualifier, getTimestampFromServer, getTimestampQuery, getUpdateSequenceQuery, hasDefaultSequence, initializeDefaultQueries, isAccess, isAttunity, isCloudscape, isDB2, isDB2Z, isDBase, isDerby, isFirebird, isH2, isHANA, isHSQL, isMaxDB, isMySQL, isODBC, isOracle, isOracle23, isOracle9, isPervasive, isPointBase, isPostgreSQL, isSQLAnywhere, isSQLServer, isSybase, isSymfoware, isTimesTen, isTimesTen7, removeAllSequences, removeSequence, sequencesAfterCloneCleanup, setConversionManager, setDefaultNativeSequenceToTable, setDefaultSeqenceAtNextValue, setDefaultSequence, setEndDelimiter, setSelectSequenceNumberQuery, setSequencePreallocationSize, setSequences, setStartDelimiter, setSupportsReturnGeneratedKeys, setTableQualifier, setTimestampQuery, setUpdateSequenceQuery, shouldNativeSequenceUseTransaction, shouldPrepare, shouldSelectDistinctIncludeOrderBy, supportsNativeSequenceNumbers, supportsReturnGeneratedKeys, toString, usesPlatformDefaultSequence
-
-
-
-
Constructor Detail
-
Informix11Platform
public Informix11Platform()
Creates a newInformix11Platform. CallsDatabasePlatform.setShouldBindLiterals(boolean)withfalseas a parameter value.- See Also:
- EclipseLink bug 401718
-
-
Method Detail
-
initializePlatformOperators
protected void initializePlatformOperators()
Fixes EclipseLink bug 402600 by making sure that theDistinctExpressionOperatoris set to print asDISTINCT (no parentheses, one trailing space), and fixes EclipseLink bug 402953 by adding platform operators for current date and current time.- Overrides:
initializePlatformOperatorsin classorg.eclipse.persistence.internal.databaseaccess.DatasourcePlatform- See Also:
currentDateOperator(),currentTimeOperator(), EclipseLink bug 402600, EclipseLink bug 402953
-
currentDateOperator
protected ExpressionOperator currentDateOperator()
Fixes EclipseLink bug 402953 by returning the result of running the following code:ExpressionOperator.simpleFunctionNoParentheses(ExpressionOperator.CurrentDate, "CURRENT YEAR TO DAY");- Returns:
- a non-
nullExpressionOperator - See Also:
- EclipseLink bug 402953
-
currentTimeOperator
protected ExpressionOperator currentTimeOperator()
Fixes EclipseLink bug 402953 by returning the result of running the following code:ExpressionOperator.simpleFunctionNoParentheses(ExpressionOperator.CurrentDate, "CURRENT YEAR TO FRACTION(3)");- Returns:
- a non-
nullExpressionOperatorEclipseLink bug 402953
-
distinctOperator
protected ExpressionOperator distinctOperator()
Fixes EclipseLink bug 402600 by making sure that theDistinctExpressionOperatoris set to print asDISTINCT (no parentheses, one trailing space), and fixes- See Also:
- EclipseLink bug 402600
-
isInformixOuterJoin
public boolean isInformixOuterJoin()
Overrides the default behavior to returnfalse, indicating that ANSIOUTER JOINsyntax should be used, since all modern versions of Informix support it.- Overrides:
isInformixOuterJoinin classInformixPlatform- Returns:
falsewhen invoked- See Also:
- EclipseLink bug 401393
-
appendBoolean
protected void appendBoolean(java.lang.Boolean booleanValue, java.io.Writer writer) throws java.io.IOExceptionFixes EclipseLink bug 401746 by writing out either't'or'f'—with single quotes— instead of1or0.- Overrides:
appendBooleanin classorg.eclipse.persistence.internal.databaseaccess.DatabasePlatform- Parameters:
booleanValue- a non-nullBooleanto appendwriter- a non-nullWriterto append the literal value to- Throws:
java.lang.IllegalArgumentException- if eitherbooleanValueorwriterisnulljava.io.IOException- if the suppliedWriterthrows anIOException- See Also:
- EclipseLink bug 401393
-
dontBindUpdateAllQueryUsingTempTables
public boolean dontBindUpdateAllQueryUsingTempTables()
Returnstruewhen invoked to indicate that parameter binding must not be used when working with temporary tables as part of anUPDATEquery.Parsing the English is a little difficult in this method name. It means: "Do not bind parameters in queries that are part of an overall 'update all' operation where temporary tables are being used."
- Overrides:
dontBindUpdateAllQueryUsingTempTablesin classorg.eclipse.persistence.internal.databaseaccess.DatabasePlatform- Returns:
truewhen invoked- See Also:
- EclipseLink bug 402037
-
shouldAlwaysUseTempStorageForModifyAll
public boolean shouldAlwaysUseTempStorageForModifyAll()
Returnstruewhen invoked to force Informix to use temporary storage when constructing bulkUPDATEstatements.- Overrides:
shouldAlwaysUseTempStorageForModifyAllin classorg.eclipse.persistence.internal.databaseaccess.DatabasePlatform- Returns:
truein all cases- See Also:
- EclipseLink bug 402037
-
supportsLocalTempTables
public boolean supportsLocalTempTables()
Returnstruewhen invoked to indicate that Informix does indeed support local temporary tables.local is defined by EclipseLink in
DatabasePlatformto mean:"Local" means that several threads may create temporary tables with the same name. Local temporary table is created in the beginning of
UpdateAllQueryexecution and dropped in the end of it.- Overrides:
supportsLocalTempTablesin classorg.eclipse.persistence.internal.databaseaccess.DatabasePlatform- Returns:
truewhen invoked- See Also:
- EclipseLink bug 402037
-
getCreateTempTableSqlPrefix
protected java.lang.String getCreateTempTableSqlPrefix()
ReturnsCREATE TEMP TABLEwhen invoked, per the Informix 11.70 Information Center documentation.While Informix 11.70 supports an additional
IF NOT EXISTSclause, Informix 11.50 does not, so this method does not add theIF NOT EXISTSclause. In practice this should be fine as temporary tables are scoped to the Informix session, and EclipseLink takes care of cleaning up any temporary tables that it creates.- Overrides:
getCreateTempTableSqlPrefixin classorg.eclipse.persistence.internal.databaseaccess.DatabasePlatform- Returns:
CREATE TEMP TABLEwhen invoked- See Also:
- EclipseLink bug 402037
-
getTempTableForTable
public org.eclipse.persistence.internal.helper.DatabaseTable getTempTableForTable(org.eclipse.persistence.internal.helper.DatabaseTable table)
Overrides the superclass implementation to return a newDatabaseTablewith no DatabaseTable.getTableQualifier(). Informix 11.50 and above do not support table qualifiers of any kind on temporary tables.- Overrides:
getTempTableForTablein classorg.eclipse.persistence.internal.databaseaccess.DatabasePlatform- Parameters:
table- theDatabaseTablefor which a temporaryDatabaseTableshould be returned; must not benull- Returns:
- a new
DatabaseTablewith no table qualifier - Throws:
java.lang.IllegalArgumentException- iftableisnull- See Also:
- EclipseLink bug 402037, EclipseLink bug 402180
-
getCreateTempTableSqlSuffix
protected java.lang.String getCreateTempTableSqlSuffix()
ReturnsWITH NO LOGwhen invoked, per the Informix 11.70 Information Center documentation, since transactions are not needed on temp tables for the purposes for which EclipseLink uses them.- Overrides:
getCreateTempTableSqlSuffixin classorg.eclipse.persistence.internal.databaseaccess.DatabasePlatform- Returns:
WITH NO LOGwhen invoked- See Also:
- EclipseLink bug 402037
-
writeUpdateOriginalFromTempTableSql
public void writeUpdateOriginalFromTempTableSql(java.io.Writer writer, org.eclipse.persistence.internal.helper.DatabaseTable table, java.util.Collection pkFields, java.util.Collection assignedFields) throws java.io.IOExceptionOverridesDatabasePlatform.writeUpdateOriginalFromTempTableSql(Writer, DatabaseTable, Collection, Collection)to ensure that aSETclause that is supposed to set a value for only one column does not wrap that column name in parentheses.The code for this method is identical to that of the stock
H2Platform, since the H2 database has the same requirement.- Overrides:
writeUpdateOriginalFromTempTableSqlin classorg.eclipse.persistence.internal.databaseaccess.DatabasePlatform- Parameters:
writer- theWriterthat will be writing SQL; must not benulltable- theDatabaseTableto be updated; must not benullpkFields- aCollectionofDatabaseFields each of which is a primary key of the table to be updated; must not benullassignedFields- aCollectionofDatabaseFields that are receiving updated values; must not benull- Throws:
java.io.IOException- if an input/output error is thrown by the suppliedWriterjava.lang.NullPointerException- if any of the supplied parameters isnull- See Also:
- EclipseLink bug 402037
-
getObjectFromResultSet
public java.lang.Object getObjectFromResultSet(java.sql.ResultSet resultSet, int columnNumber, int jdbcType, org.eclipse.persistence.internal.sessions.AbstractSession session) throws java.sql.SQLExceptionOverridesDatabasePlatform.getObjectFromResultSet(ResultSet, int, int, AbstractSession)so that if the suppliedjdbcTypeis equal toTypes.LONGVARCHAR, then theResultSet.getString(int)method (instead of theResultSet.getObject(int)method) is used to fetch the "raw" value of the column indicated by the suppliedcolumnNumberfrom the suppliedResultSet.This works around an issue with the Informix JDBC driver, version 3.70.JC7 and earlier, where a
TEXTcolumn is reported to be mappable to the JDBC type ofLONGVARCHAR, but the actual object returned byResultSet.getObject(int)is abyte[](instead of either achar[]or aString). InvokingResultSet.getString(int)instead returns the desired result.- Overrides:
getObjectFromResultSetin classorg.eclipse.persistence.internal.databaseaccess.DatabasePlatform- Parameters:
resultSet- theResultSetto get anObjectfrom; may benullcolumnNumber- the1-based column number indicating the column to usejdbcType- anintindicating the JDBC type of which the column in theResultSetindicated by the suppliedcolumnNumberis expected to besession- anAbstractSessionthat, when used at all, is passed to the superclass implementation of this method; may benull- Returns:
- the
Objectresulting from a call toResultSet.getObject(int); may benull - Throws:
java.sql.SQLException- if any error occurs- See Also:
- EclipseLink bug 405645
-
-