Easysoft
ODBC Drivers for Oracle, SQL Server, Firebird, ISAM, InterBase, Sybase, MS Access & more.

ODBC Status Return Codes

0100001001010020100301004010060100701S0001S0101S0201S0601S0701S0801S09
070010700207005070060700907S01
080010800208003080040800708S01
21S0121S02
2200122002220032200722008220122201522018220192202522026
23000
24000
2500025S0125S0225S03
28000
34000
3C000
3D000
3F000
400014000240003
4200042S0142S0242S1142S1242S2142S22
44000
HY000HY001HY003HY004HY007HY008HY009HY010HY011HY012HY013HY014HY015HY016HY017
HY018HY019HY020HY021HY024HY090HY091HY092HY095HY096HY097HY098HY099
HY100HY101HY103HY104HY105HY106HY107HY109HY110HY111HYC00HYT00HYT01
IM001IM002IM003IM004IM005IM006IM007IM008IM009IM010IM011IM012IM013IM014IM015

SQLSTATE 01

SQLSTATEErrorCan be returned from
01000General warning
01001Cursor operation conflict
  • SQLExecDirect

    StatementText contained a positioned update or delete statement, and no rows or more than one row were updated or deleted. (For more information about updates to more than one row, see the description of the SQL_ATTR_SIMULATE_CURSOR Attribute in SQLSetStmtAttr.)

    (Function returns SQL_SUCCESS_WITH_INFO)

  • SQLExecute

    The prepared statement associated with the StatementHandle contained a positioned update or delete statement, and no rows or more than one row were updated or deleted. (For more information about updates to more than one row, see the description of the SQL_ATTR_SIMULATE_CURSOR Attribute in SQLSetStmtAttr.)

    (Function returns SQL_SUCCESS_WITH_INFO.)

  • SQLParamData
  • SQLSetPos

    The Operation argument was SQL_DELETE or SQL_UPDATE, and no rows or more than one row were deleted or updated. (For more information about updates to more than one row, see the description of the SQL_ATTR_SIMULATE_CURSOR Attribute in SQLSetStmtAttr.)

    (Function returns SQL_SUCCESS_WITH_INFO.)

    The Operation argument was SQL_DELETE or SQL_UPDATE, and the operation failed because of optimistic concurrency. (Function returns SQL_SUCCESS_WITH_INFO.)

01002Disconnect error
  • SQLDisconnect

    An error occurred during the disconnect. However, the disconnect succeeded. (Function returns SQL_SUCCESS_WITH_INFO.)

01003NULL value eliminated in set function
  • SQLExecDirect

    The argument StatementText contained a set function (such as AVG, MAX, MIN, and so on), but not the COUNT set function, and NULL argument values were eliminated before the function was applied. (Function returns SQL_SUCCESS_WITH_INFO.)

  • SQLExecute

    The prepared statement associated with StatementHandle contained a set function (such as AVG, MAX, MIN, and so on), but not the COUNT set function, and NULL argument values were eliminated before the function was applied. (Function returns SQL_SUCCESS_WITH_INFO.)

  • SQLParamData
01004String data, right-truncated
  • SQLBrowseConnect

    The buffer *OutConnectionString was not large enough to return the entire browse result connection string, so the string was truncated. The buffer *StringLength2Ptr contains the length of the untruncated browse result connection string. (Function returns SQL_SUCCESS_WITH_INFO.)

  • SQLBulkOperations

    The Operation argument was SQL_FETCH_BY_BOOKMARK, and string or binary data returned for a column or columns with a data type of SQL_C_CHAR or SQL_C_BINARY resulted in the truncation of nonblank character or non-NULL binary data.

  • SQLColAttribute

    The buffer *CharacterAttributePtr was not large enough to return the entire string value, so the string value was truncated. The length of the untruncated string value is returned in *StringLengthPtr. (Function returns SQL_SUCCESS_WITH_INFO.)

  • SQLDataSources

    (DM) The buffer *ServerName was not large enough to return the entire data source name, so the name was truncated. The length of the entire data source name is returned in *NameLength1Ptr. (Function returns SQL_SUCCESS_WITH_INFO.)

    (DM) The buffer *Description was not large enough to return the entire driver description, so the description was truncated. The length of the untruncated data source description is returned in *NameLength2Ptr. (Function returns SQL_SUCCESS_WITH_INFO.)

  • SQLDescribeCol

    The buffer *ColumnName was not large enough to return the entire column name, so the column name was truncated. The length of the untruncated column name is returned in *NameLengthPtr. (Function returns SQL_SUCCESS_WITH_INFO.)

  • SQLDriverConnect

    The buffer *OutConnectionString was not large enough to return the entire connection string, so the connection string was truncated. The length of the untruncated connection string is returned in *StringLength2Ptr. (Function returns SQL_SUCCESS_WITH_INFO.)

  • SQLDrivers

    (DM) The buffer *DriverDescription was not large enough to return the entire driver description, so the description was truncated. The length of the entire driver description is returned in *DescriptionLengthPtr. (Function returns SQL_SUCCESS_WITH_INFO.)

    (DM) The buffer *DriverAttributes was not large enough to return the entire list of attribute value pairs, so the list was truncated. The length of the untruncated list of attribute value pairs is returned in *AttributesLengthPtr. (Function returns SQL_SUCCESS_WITH_INFO.)

  • SQLExecDirect

    String or binary data returned for an input/output or output parameter resulted in the truncation of nonblank character or non-NULL binary data. If it was a string value, it was right-truncated. (Function returns SQL_SUCCESS_WITH_INFO.)

  • SQLExecute

    String or binary data returned for an output parameter resulted in the truncation of nonblank character or non-NULL binary data. If it was a string value, it was right-truncated. (Function returns SQL_SUCCESS_WITH_INFO.)

  • SQLExtendedFetch

    String or binary data returned for a column resulted in the truncation of nonblank character or non-NULL binary data. If it was a string value, it was right-truncated. If it was a numeric value, the fractional part of the number was truncated.

    (Function returns SQL_SUCCESS_WITH_INFO.)

  • SQLFetch

    String or binary data returned for a column resulted in the truncation of nonblank character or non-NULL binary data. If it was a string value, it was right-truncated.

  • SQLFetchScroll

    String or binary data returned for a column resulted in the truncation of nonblank character or non-NULL binary data. String values are right-truncated.

  • SQLGetConnectAttr

    The data returned in *ValuePtr was truncated to be BufferLength minus the length of a null-termination character. The length of the untruncated string value is returned in *StringLengthPtr.

    (Function returns SQL_SUCCESS_WITH_INFO.)

  • SQLGetCursorName

    The buffer *CursorName was not large enough to return the entire cursor name, so the cursor name was truncated. The length of the untruncated cursor name is returned in *NameLengthPtr.

    (Function returns SQL_SUCCESS_WITH_INFO.)

  • SQLGetData

    Not all of the data for the specified column, ColumnNumber, could be retrieved in a single call to the function. The length of the data remaining in the specified column prior to the current call to SQLGetData is returned in *StrLen_or_IndPtr. (Function returns SQL_SUCCESS_WITH_INFO.)

    The TargetValuePtr argument was a null pointer, and more data was available to return. (Function returns SQL_SUCCESS_WITH_INFO.)

    For more information on using multiple calls to SQLGetData> for a single column, see "Comments."

  • SQLGetDescField

    The buffer *ValuePtr was not large enough to return the entire descriptor field, so the field was truncated. The length of the untruncated descriptor field is returned in *StringLengthPtr. (Function returns SQL_SUCCESS_WITH_INFO.)

  • SQLGetDescRec

    The buffer *Name was not large enough to return the entire descriptor field, so the field was truncated. The length of the untruncated descriptor field is returned in *StringLengthPtr. (Function returns SQL_SUCCESS_WITH_INFO.)

  • SQLGetEnvAttr

    The data returned in *ValuePtr was truncated to be BufferLength minus the null-termination character. The length of the untruncated string value is returned in *StringLengthPtr. (Function returns SQL_SUCCESS_WITH_INFO.)

  • SQLGetInfo

    The buffer *InfoValuePtr was not large enough to return all of the requested information, so the information was truncated. The length of the requested information in its untruncated form is returned in *StringLengthPtr. (Function returns SQL_SUCCESS_WITH_INFO.)

  • SQLGetStmtAttr

    The data returned in *ValuePtr was truncated to be BufferLength minus the length of a null-termination character. The length of the untruncated string value is returned in *StringLengthPtr. (Function returns SQL_SUCCESS_WITH_INFO.)

  • SQLNativeSql

    The buffer *OutStatementText was not large enough to return the entire SQL string, so the SQL string was truncated. The length of the untruncated SQL string is returned in *TextLength2Ptr. (Function returns SQL_SUCCESS_WITH_INFO.)

  • SQLParamData
  • SQLPutData

    String or binary data returned for an output parameter resulted in the truncation of nonblank character or non-NULL binary data. If it was a string value, it was right-truncated. (Function returns SQL_SUCCESS_WITH_INFO.)

  • SQLSetCursorName

    The cursor name exceeded the maximum limit, so only the maximum allowable number of characters was used.

  • SQLSetPos

    The Operation argument was SQL_REFRESH, and string or binary data returned for a column or columns with a data type of SQL_C_CHAR or SQL_C_BINARY resulted in the truncation of nonblank character or non-NULL binary data.

01006Privilege not revoked
  • SQLExecDirect

    *StatementText contained a REVOKE statement, and the user did not have the specified privilege. (Function returns SQL_SUCCESS_WITH_INFO.)

  • SQLExecute

    The prepared statement associated with the StatementHandle was a REVOKE statement, and the user did not have the specified privilege. (Function returns SQL_SUCCESS_WITH_INFO.)

  • SQLParamData
01007Privilege not granted
  • SQLExecDirect

    *StatementText was a GRANT statement, and the user could not be granted the specified privilege.

  • SQLExecute

    The prepared statement associated with the StatementHandle was a GRANT statement, and the user could not be granted the specified privilege.

  • SQLParamData
01S00Invalid connection string attribute
  • SQLBrowseConnect

    An invalid attribute keyword was specified in the browse request connection string (InConnectionString). (Function returns SQL_NEED_DATA.)

    An attribute keyword was specified in the browse request connection string (InConnectionString) that does not apply to the current connection level. (Function returns SQL_NEED_DATA.)

  • SQLDriverConnect

    An invalid attribute keyword was specified in the connection string (InConnectionString), but the driver was able to connect to the data source anyway. (Function returns SQL_SUCCESS_WITH_INFO.)

01S01Error in row
  • SQLBulkOperations

    The Operation argument was SQL_ADD, and an error occurred in one or more rows while performing the operation but at least one row was successfully added. (Function returns SQL_SUCCESS_WITH_INFO.)

    (This error is raised only when an application is working with an ODBC 2.x driver.)

  • SQLExtendedFetch

    An error occurred while fetching one or more rows. (Function returns SQL_SUCCESS_WITH_INFO.)

  • SQLFetch

    An error occurred while fetching one or more rows.

    (If this SQLSTATE is returned when an ODBC 3.x application is working with an ODBC 2.x driver, it can be ignored.)

  • SQLFetchScroll

    An error occurred while fetching one or more rows.

    (This SQLSTATE is returned only by ODBC 2.x drivers.)

  • SQLSetPos

    The RowNumber argument was 0, and an error occurred in one or more rows while performing the operation specified with the Operation argument.

    (SQL_SUCCESS_WITH_INFO is returned if an error occurs on one or more, but not all, rows of a multirow operation, and SQL_ERROR is returned if an error occurs on a single-row operation.)

    (This SQLSTATE is returned only when SQLSetPos is called after SQLExtendedFetch, if the driver is an ODBC 2.x driver and the cursor library is not used.)

01S02Option value changed
  • SQLBrowseConnect

    The driver did not support the specified value of the ValuePtr argument in SQLSetConnectAttr and substituted a similar value.

    (Function returns SQL_SUCCESS_WITH_INFO.)

  • SQLConnect

    The driver did not support the specified value of the ValuePtr argument in SQLSetConnectAttr and substituted a similar value. (Function returns SQL_SUCCESS_WITH_INFO.)

  • SQLDriverConnect

    The driver did not support the specified value pointed to by the ValuePtr argument in SQLSetConnectAttr and substituted a similar value. (Function returns SQL_SUCCESS_WITH_INFO.)

  • SQLExecDirect, SQLExecute, SQLGetTypeInfo

    A specified statement attribute was invalid because of implementation working conditions, so a similar value was temporarily substituted. ( SQLGetStmtAttr can be called to determine what the temporarily substituted value is.) The substitute value is valid for the StatementHandle until the cursor is closed, at which point the statement attribute reverts to its previous value. The statement attributes that can be changed are:
    SQL_ATTR_CONCURRENCY
    SQL_ATTR_CURSOR_TYPE
    SQL_ATTR_KEYSET_SIZE
    SQL_ATTR_MAX_LENGTH
    SQL_ATTR_MAX_ROWS
    SQL_ATTR_QUERY_TIMEOUT
    SQL_ATTR_SIMULATE_CURSOR

    Function returns SQL_SUCCESS_WITH_INFO.)

  • SQLMoreResults

    The value of a statement attribute changed as the batch was being processed. (Function returns SQL_SUCCESS_WITH_INFO.)

  • SQLParamData
  • SQLPrepare

    A specified statement attribute was invalid because of implementation working conditions, so a similar value was temporarily substituted. (SQLGetStmtAttr can be called to determine what the temporarily substituted value is.) The substitute value is valid for the StatementHandle until the cursor is closed. The statement attributes that can be changed are:
    SQL_ATTR_CONCURRENCY
    SQL_ATTR_CURSOR_TYPE
    SQL_ATTR_KEYSET_SIZE
    SQL_ATTR_MAX_LENGTH
    SQL_ATTR_MAX_ROWS
    SQL_ATTR_QUERY_TIMEOUT
    SQL_ATTR_SIMULATE_CURSOR

    (Function returns SQL_SUCCESS_WITH_INFO.)

  • SQLSetConnectAttr

    The driver did not support the value specified in ValuePtr and substituted a similar value. (Function returns SQL_SUCCESS_WITH_INFO.)

  • SQLSetDescField

    The driver did not support the value specified in *ValuePtr (if ValuePtr was a pointer) or the value in ValuePtr (if ValuePtr was a 4-byte value), or *ValuePtr was invalid because of implementation working conditions, so the driver substituted a similar value. (Function returns SQL_SUCCESS_WITH_INFO.)

  • SQLSetEnvAttr

    The driver did not support the value specified in ValuePtr and substituted a similar value. (Function returns SQL_SUCCESS_WITH_INFO.)

  • SQLSetStmtAttr

    The driver did not support the value specified in ValuePtr, or the value specified in ValuePtr was invalid because of implementation working conditions, so the driver substituted a similar value. (SQLGetStmtAttr can be called to determine the temporarily substituted value.) The substitute value is valid for the StatementHandle until the cursor is closed, at which point the statement attribute reverts to its previous value. The statement attributes that can be changed are: SQL_ATTR_CONCURRENCY
    SQL_ATTR_CURSOR_TYPE
    SQL_ATTR_KEYSET_SIZE
    SQL_ATTR_MAX_LENGTH
    SQL_ATTR_MAX_ROWS
    SQL_ATTR_QUERY_TIMEOUT
    SQL_ATTR_ROW_ARRAY_SIZE
    SQL_ATTR_SIMULATE_CURSOR

    (Function returns SQL_SUCCESS_WITH_INFO.)

01S06Attempt to fetch before the result set returned the first rowset
  • SQLExtendedFetch

    The requested rowset overlapped the start of the result set when the current position was beyond the first row, and either FetchOrientation was SQL_PRIOR or FetchOrientation was SQL_RELATIVE with a negative FetchOffset whose absolute value was less than or equal to the current SQL_ROWSET_SIZE. (Function returns SQL_SUCCESS_WITH_INFO.)

  • SQLFetchScroll

    The requested rowset overlapped the start of the result set when FetchOrientation was SQL_FETCH_PRIOR, the current position was beyond the first row, and the number of the current row is less than or equal to the rowset size.

    The requested rowset overlapped the start of the result set when FetchOrientation was SQL_FETCH_PRIOR, the current position was beyond the end of the result set, and the rowset size was greater than the result set size.

    The requested rowset overlapped the start of the result set when FetchOrientation was SQL_FETCH_RELATIVE, FetchOffset was negative, and the absolute value of FetchOffset was less than or equal to the rowset size.

    The requested rowset overlapped the start of the result set when FetchOrientation was SQL_FETCH_ABSOLUTE, FetchOffset was negative, and the absolute value of FetchOffset was greater than the result set size but less than or equal to the rowset size.

    (Function returns SQL_SUCCESS_WITH_INFO.)

01S07Fractional truncation
  • SQLBulkOperations

    The Operation argument was SQL_FETCH_BY_BOOKMARK, the data type of the application buffer was not SQL_C_CHAR or SQL_C_BINARY, and the data returned to application buffers for one or more columns was truncated. (For numeric C data types, the fractional part of the number was truncated. For time, timestamp, and interval C data types containing a time component, the fractional portion of the time was truncated.)

    (Function returns SQL_SUCCESS_WITH_INFO.)

  • SQLExecDirect, SQLExecute

    The data returned for an input/output or output parameter was truncated such that the fractional part of a numeric data type was truncated or the fractional portion of the time component of a time, timestamp, or interval data type was truncated.

    (Function returns SQL_SUCCESS_WITH_INFO.)

  • SQLExtendedFetch, SQLFetch, SQLFetchScroll

    The data returned for a column was truncated. For numeric data types, the fractional part of the number was truncated. For time, timestamp, and interval data types containing a time component, the fractional portion of the time was truncated.

    (Function returns SQL_SUCCESS_WITH_INFO.)

  • SQLGetData

    The data returned for one or more columns was truncated. For numeric data types, the fractional part of the number was truncated. For time, timestamp, and interval data types containing a time component, the fractional portion of the time was truncated.

    (Function returns SQL_SUCCESS_WITH_INFO.)

  • SQLParamData
  • SQLSetPos

    The Operation argument was SQL_REFRESH, the data type of the application buffer was not SQL_C_CHAR or SQL_C_BINARY, and the data returned to application buffers for one or more columns was truncated. For numeric data types, the fractional part of the number was truncated. For time, timestamp, and interval data types containing a time component, the fractional portion of the time was truncated.

    (Function returns SQL_SUCCESS_WITH_INFO.)

01S08Error saving File DSN
  • SQLDriverConnect

    The string in *InConnectionString contained a FILEDSN keyword, but the .dsn file was not saved. (Function returns SQL_SUCCESS_WITH_INFO.)

01S09Invalid keyword
  • SQLDriverConnect

    (DM) The string in *InConnectionString contained a SAVEFILE keyword but not a DRIVER or a FILEDSN keyword. (Function returns SQL_SUCCESS_WITH_INFO.)

Download ODBC Drivers for Oracle, SQL Server, Firebird, ISAM, InterBase, Sybase, MS Access and more.

SQLSTATE 07

SQLSTATEErrorCan be returned from
07001Wrong number of parameters
07002COUNT field incorrect
  • SQLExecDirect, SQLExecute

    The number of parameters specified in SQLBindParameter was less than the number of parameters in the SQL statement contained in *StatementText.

    SQLBindParameter was called with ParameterValuePtr set to a null pointer, StrLen_or_IndPtr not set to SQL_NULL_DATA or SQL_DATA_AT_EXEC, and InputOutputType not set to SQL_PARAM_OUTPUT, so that the number of parameters specified in SQLBindParameter was greater than the number of parameters in the SQL statement contained in *StatementText.

  • SQLParamData
07005Prepared statement not a cursor-specification
  • SQLColAttribute

    The statement associated with the StatementHandle did not return a result set and FieldIdentifier was not SQL_DESC_COUNT. There were no columns to describe.

  • SQLDescribeCol

    The statement associated with the StatementHandle did not return a result set. There were no columns to describe.

07006Restricted data type attribute violation
  • SQLBindCol

    (DM) The ColumnNumber argument was 0, and the TargetType argument was not SQL_C_BOOKMARK or SQL_C_VARBOOKMARK.

  • SQLBindParameter

    The data type identified by the ValueType argument cannot be converted to the data type identified by the ParameterType argument. Note that this error may be returned by SQLExecDirect, SQLExecute, or SQLPutData at execution time, instead of by SQLBindParameter.

  • SQLBulkOperations

    The Operation argument was SQL_FETCH_BY_BOOKMARK, and the data value of a column in the result set could not be converted to the data type specified by the TargetType argument in the call to SQLBindCol.

    The Operation argument was SQL_UPDATE_BY_BOOKMARK or SQL_ADD, and the data value in the application buffers could not be converted to the data type of a column in the result set.

  • SQLExecDirect, SQLExecute

    The data value identified by the ValueType argument in SQLBindParameter for the bound parameter could not be converted to the dataSQLBindParameter.

    The data value returned for a parameter bound as SQL_PARAM_INPUT_OUTPUT or SQL_PARAM_OUTPUT could not be converted to the data type identified by the ParameterType argument in SQLBindParameter.

    (If the data values for one or more rows could not be converted but one or more rows were successfully returned, this function returns SQL_SUCCESS_WITH_INFO.)

  • SQLExtendedFetch

    A data value could not be converted to the C data type specified by TargetType in SQLBindCol.

  • SQLFetch, SQLFetchScroll

    The data value of a column in the result set could not be converted to the data type specified by TargetType in SQLBindCol.

    Column 0 was bound with a data type of SQL_C_BOOKMARK, and the SQL_ATTR_USE_BOOKMARKS statement attribute was set to SQL_UB_VARIABLE.

    Column 0 was bound with a data type of SQL_C_VARBOOKMARK, and the SQL_ATTR_USE_BOOKMARKS statement attribute was not set to SQL_UB_VARIABLE.

  • SQLGetData

    The data value of a column in the result set cannot be converted to the C data type specified by the argument TargetType.

  • SQLParamData

    The data value identified by the ValueType argument in SQLBindParameter for the bound parameter could not be converted to the data type identified by the ParameterType argument in SQLBindParameter.

    The data value returned for a parameter bound as SQL_PARAM_INPUT_OUTPUT or SQL_PARAM_OUTPUT could not be converted to the data type identified by the ValueType argument in SQLBindParameter.

    (If the data values for one or more rows could not be converted, but one or more rows were successfully returned, this function returns SQL_SUCCESS_WITH_INFO.)

  • SQLPutData

    The data value identified by the ValueType argument in SQLBindParameter for the bound parameter could not be converted to the data type identified by the ParameterType argument in SQLBindParameter.

  • SQLSetPos

    The data value of a column in the result set could not be converted to the data type specified by TargetType in the call to SQLBindCol.

07009Invalid descriptor index
  • SQLBindCol

    The value specified for the argument ColumnNumber exceeded the maximum number of columns in the result set.

  • SQLBindParameter

    (DM) The value specified for the argument ParameterNumber was less than 1.

  • SQLBulkOperations

    The argument Operation was SQL_ADD, and a column was bound with a column number greater than the number of columns in the result set.

  • SQLColAttribute, SQLDescribeCol

    (DM) The value specified for the argument ColumnNumber was equal to 0, and the SQL_ATTR_USE_BOOKMARKS statement option was SQL_UB_OFF.

    The value specified for the argument ColumnNumber was greater than the number of columns in the result set.

  • SQLDescribeParam

    (DM) The value specified for the argument ParameterNumber is less than 1.

    The value specified for the argument ParameterNumber was greater than the number of parameters in the associated SQL statement.

    The parameter marker was part of a non-DML statement.

    The parameter marker was part of a SELECT list.

  • SQLExtendedFetch

    Column 0 was bound with SQLBindCol, and the SQL_ATTR_USE_BOOKMARKS statement attribute was set to SQL_UB_OFF.

  • SQLFetch

    The driver was an ODBC 2.x driver that does not support SQLExtendedFetch, and a column number specified in the binding for a column was 0.

    Column 0 was bound, and the SQL_ATTR_USE_BOOKMARKS statement attribute was set to SQL_UB_OFF.

  • SQLFetchScroll

    Column 0 was bound, and the SQL_ATTR_USE_BOOKMARKS statement attribute was set to SQL_UB_OFF.

  • SQLGetData

    The value specified for the argument ColumnNumber was 0, and the SQL_ATTR_USE_BOOKMARKS statement attribute was set to SQL_UB_OFF.

    The value specified for the argument ColumnNumber was greater than the number of columns in the result set.

    (DM) The specified column was bound. This description does not apply to drivers that return the SQL_GD_BOUND bitmask for the SQL_GETDATA_EXTENSIONS option in SQLGetInfo.

    (DM) The number of the specified column was less than or equal to the number of the highest bound column. This description does not apply to drivers that return the SQL_GD_ANY_COLUMN bitmask for the SQL_GETDATA_EXTENSIONS option in SQLGetInfo.

    (DM) The application has already called SQLGetData for the current row; the number of the column specified in the current call was less than the number of the column specified in the preceding call; and the driver does not return the SQL_GD_ANY_ORDER bitmask for the SQL_GETDATA_EXTENSIONS option in SQLGetInfo.

    (DM) The TargetType argument was SQL_ARD_TYPE, and the ColumnNumber descriptor record in the ARD failed the consistency check.

    (DM) The TargetType argument was SQL_ARD_TYPE, and the value in the SQL_DESC_COUNT field of the ARD was less than the ColumnNumber argument.

  • SQLGetDescField

    (DM) The RecNumber argument was equal to 0, the SQL_ATTR_USE_BOOKMARK statement attribute was SQL_UB_OFF, and the DescriptorHandle argument was an IRD handle. (This error can be returned for an explicitly allocated descriptor only if the descriptor is associated with a statement handle.)

    The FieldIdentifier argument was a record field, the RecNumber argument was 0, and the DescriptorHandle argument was an IPD handle.

    The RecNumber argument was less than 0.

  • SQLGetDescRec

    The FieldIdentifier argument was a record field, the RecNumber argument was set to 0, and the DescriptorHandle argument was an IPD handle.

    (DM) The RecNumber argument was set to 0, and the SQL_ATTR_USE_BOOKMARKS statement attribute was set to SQL_UB_OFF, and the DescriptorHandle argument was an IRD handle.

    The RecNumber argument was less than 0.

  • SQLParamData
  • SQLSetDescField

    The FieldIdentifier argument was a record field, the RecNumber argument was 0, and the DescriptorHandle argument referred to an IPD handle.

    The RecNumber argument was less than 0, and the DescriptorHandle argument referred to an ARD or an APD.

    The RecNumber argument was greater than the maximum number of columns or parameters that the data source can support, and the DescriptorHandle argument referred to an APD or ARD.

    (DM) The FieldIdentifier argument was SQL_DESC_COUNT, and *ValuePtr argument was less than 0.

    The RecNumber argument was equal to 0, and the DescriptorHandle argument referred to an implicitly allocated APD. (This error does not occur with an explicitly allocated application descriptor, because it is not known whether an explicitly allocated application descriptor is an APD or ARD until execute time.)

  • SQLSetDescRec

    The RecNumber argument was set to 0, and the DescriptorHandle referred to an IPD handle.

    The RecNumber argument was less than 0.

    The RecNumber argument was greater than the maximum number of columns or parameters that the data source can support, and the DescriptorHandle argument was an APD, IPD, or ARD.

    The RecNumber argument was equal to 0, and the DescriptorHandle argument referred to an implicitly allocated APD. (This error does not occur with an explicitly allocated application descriptor because it is not known whether an explicitly allocated application descriptor is an APD or ARD until execute time.)

  • SQLSetPos

    The argument Operation was SQL_REFRESH or SQL_UPDATE, and a column was bound with a column number greater than the number of columns in the result set.

07S01Invalid use of default parameter

Download ODBC Drivers for Oracle, SQL Server, Firebird, ISAM, InterBase, Sybase, MS Access and more.

SQLSTATE 08

SQLSTATEErrorCan be returned from
08001Client unable to establish connection
08002Connection name in use
  • SQLBrowseConnect

    (DM) The specified connection had already been used to establish a connection with a data source, and the connection was open.

  • SQLConnect

    (DM) The specified ConnectionHandle had already been used to establish a connection with a data source, and the connection was still open or the user was browsing for a connection.

  • SQLDriverConnect

    (DM) The specified ConnectionHandle had already been used to establish a connection with a data source, and the connection was still open.

  • SQLSetConnectAttr

    The Attribute argument was SQL_ATTR_ODBC_CURSORS, and the driver was already connected to the data source.

08003Connection does not exist
  • SQLAllocHandle

    (DM) The HandleType argument was SQL_HANDLE_STMT or SQL_HANDLE_DESC, but the connection specified by the InputHandle argument was not open. The connection process must be completed successfully (and the connection must be open) for the driver to allocate a statement or descriptor handle.

  • SQLDisconnect

    (DM) The connection specified in the argument ConnectionHandle was not open.

  • SQLEndTran

    (DM) The HandleType was SQL_HANDLE_DBC, and the Handle was not in a connected state.

  • SQLGetConnectAttr

    (DM) An Attribute value that required an open connection was specified.

  • SQLGetInfo

    (DM) The type of information requested in InfoType requires an open connection. Of the information types reserved by ODBC, only SQL_ODBC_VER can be returned without an open connection.

  • SQLNativeSql

    The ConnectionHandle was not in a connected state.

  • SQLSetConnectAttr

    (DM) An Attribute value was specified that required an open connection, but the ConnectionHandle was not in a connected state.

08004Server rejected the connection
08007Connection failure during transaction
  • SQLEndTran

    The HandleType was SQL_HANDLE_DBC, and the connection associated with the Handle failed during the execution of the function, and it cannot be determined whether the requested COMMIT or ROLLBACK occurred before the failure.

08S01Communication link failure

Download ODBC Drivers for Oracle, SQL Server, Firebird, ISAM, InterBase, Sybase, MS Access and more.

SQLSTATE 21

SQLSTATEErrorCan be returned from
21S01Insert value list does not match column list
  • SQLDescribeParam

    The number of parameters in the INSERT statement did not match the number of columns in the table named in the statement.

  • SQLExecDirect, SQLPrepare

    *StatementText contained an INSERT statement, and the number of values to be inserted did not match the degree of the derived table.

21S02Degree of derived table does not match column list
  • SQLBulkOperations

    The argument Operation was SQL_UPDATE_BY_BOOKMARK; and no columns were updateable because all columns were either unbound or read-only, or the value in the bound length/indicator buffer was SQL_COLUMN_IGNORE.

  • SQLExecDirect

    *StatementText contained a CREATE VIEW statement, and the unqualified column list (the number of columns specified for the view in the column-identifier arguments of the SQL statement) contained more names than the number of columns in the derived table defined by the query-specification argument of the SQL statement.

  • SQLExecute

    The prepared statement associated with the StatementHandle contained a CREATE VIEW statement, and the unqualified column list (the number of columns specified for the view in the column-identifier arguments of the SQL statement) contained more names than the number of columns in the derived table defined by the query-specification argument of the SQL statement.

  • SQLParamData
  • SQLPrepare

    *StatementText contained a CREATE VIEW statement, and the number of names specified is not the same degree as the derived table defined by the query specification.

  • SQLSetPos

    The argument Operation was SQL_UPDATE, and no columns were updateable because all columns were either unbound, read-only, or the value in the bound length/indicator buffer was SQL_COLUMN_IGNORE.

Download ODBC Drivers for Oracle, SQL Server, Firebird, ISAM, InterBase, Sybase, MS Access and more.

SQLSTATE 22

SQLSTATEErrorCan be returned from
22001String data, right-truncated
  • SQLBulkOperations

    The assignment of a character or binary value to a column in the result set resulted in the truncation of nonblank (for characters) or non-null (for binary) characters or bytes.

  • SQLExecDirect

    The assignment of a character or binary value to a column resulted in the truncation of nonblank character data or non-null binary data.

  • SQLExecute

    The assignment of a character or binary value to a column resulted in the truncation of nonblank (character) or non-null (binary) characters or bytes.

  • SQLFetch

    A variable-length bookmark returned for a column was truncated.

  • SQLFetchScroll

    A variable-length bookmark returned for a row was truncated.

  • SQLParamData
  • SQLPutData

    The assignment of a character or binary value to a column resulted in the truncation of nonblank (character) or non-null (binary) characters or bytes.

    The SQL_NEED_LONG_DATA_LEN information type in SQLGetInfo was "Y", and more data was sent for a long parameter (the data type was SQL_LONGVARCHAR, SQL_LONGVARBINARY, or a long data source�specific data type) than was specified with the StrLen_or_IndPtr argument in SQLBindParameter.

    The SQL_NEED_LONG_DATA_LEN information type in SQLGetInfo was "Y", and more data was sent for a long column (the data type was SQL_LONGVARCHAR, SQL_LONGVARBINARY, or a long data source-specific data type) than was specified in the length buffer corresponding to a column in a row of data that was added or updated with SQLBulkOperations or updated with SQLSetPos.

  • SQLSetDescField

    The FieldIdentifier argument was SQL_DESC_NAME, and the BufferLength argument was a value larger than SQL_MAX_IDENTIFIER_LEN.

  • SQLSetPos

    The Operation argument was SQL_UPDATE, and the assignment of a character or binary value to a column resulted in the truncation of nonblank (for characters) or non-null (for binary) characters or bytes.

22002Indicator variable required but not supplied
22003Numeric value out of range
  • SQLBulkOperations

    The Operation argument was SQL_ADD or SQL_UPDATE_BY_BOOKMARK, and the assignment of a numeric value to a column in the result set caused the whole (as opposed to fractional) part of the number to be truncated.

    The argument Operation was SQL_FETCH_BY_BOOKMARK, and returning the numeric value for one or more bound columns would have caused a loss of significant digits.

  • SQLExecDirect

    *StatementText contained an SQL statement that contained a bound numeric parameter or literal, and the value caused the whole (as opposed to fractional) part of the number to be truncated when assigned to the associated table column.

    Returning a numeric value (as numeric or string) for one or more input/output or output parameters would have caused the whole (as opposed to fractional) part of the number to be truncated.

  • SQLExecute

    The prepared statement associated with the StatementHandle contained a bound numeric parameter, and the parameter value caused the whole (as opposed to fractional) part of the number to be truncated when assigned to the associated table column.

    Returning a numeric value (as numeric or string) for one or more input/output or output parameters would have caused the whole (as opposed to fractional) part of the number to be truncated.

  • SQLExtendedFetch

    Returning the numeric value (as numeric or string) for one or more columns would have caused the whole (as opposed to fractional) part of the number to be truncated.

    (Function returns SQL_SUCCESS_WITH_INFO.)

    For more information, see Guidelines for Interval and Numeric Data Types in Appendix D: Data Types.

  • SQLFetch

    Returning the numeric value (as numeric or string) for one or more bound columns would have caused the whole (as opposed to fractional) part of the number to be truncated.

    For more information, see Converting Data from SQL to C Data Types in Appendix D: Data Types.

  • SQLFetchScroll

    Returning the numeric value (as numeric or string) for one or more bound columns would have caused the whole (as opposed to fractional) part of the number to be truncated.

    For more information, see Guidelines for Interval and Numeric Data Types in Appendix D: Data Types.

  • SQLGetData

    Returning the numeric value (as numeric or string) for the column would have caused the whole (as opposed to fractional) part of the number to be truncated.

    For more information, see Appendix D: Data Types.

  • SQLGetInfo
  • SQLParamData
  • SQLPutData

    The data sent for a bound numeric parameter or column caused the whole (as opposed to fractional) part of the number to be truncated when assigned to the associated table column.

    Returning a numeric value (as numeric or string) for one or more input/output or output parameters would have caused the whole (as opposed to fractional) part of the number to be truncated.

  • SQLSetPos

    The argument Operation was SQL_UPDATE, and the assignment of a numeric value to a column in the result set caused the whole (as opposed to fractional) part of the number to be truncated.

    The argument Operation was SQL_REFRESH, and returning the numeric value for one or more bound columns would have caused a loss of significant digits.

22007Invalid datetime format
  • SQLBulkOperations

    The Operation argument was SQL_ADD or SQL_UPDATE_BY_BOOKMARK, and the assignment of a date or timestamp value to a column in the result set caused the year, month, or day field to be out of range.

    The argument Operation was SQL_FETCH_BY_BOOKMARK, and returning the date or timestamp value for one or more bound columns would have caused the year, month, or day field to be out of range.

  • SQLExecDirect

    *StatementText contained an SQL statement that contained a date, time, or timestamp structure as a bound parameter, and the parameter was, respectively, an invalid date, time, or timestamp.

    An input/output or output parameter was bound to a date, time, or timestamp C structure, and a value in the returned parameter was, respectively, an invalid date, time, or timestamp. (Function returns SQL_SUCCESS_WITH_INFO.)

  • SQLExecute

    The prepared statement associated with the StatementHandle contained an SQL statement that contained a date, time, or timestamp structure as a bound parameter, and the parameter was, respectively, an invalid date, time, or timestamp.

    An input/output or output parameter was bound to a date, time, or timestamp C structure, and a value in the returned parameter was, respectively, an invalid date, time, or timestamp. (Function returns SQL_SUCCESS_WITH_INFO.)

  • SQLExtendedFetch

    A character column in the result set was bound to a date, time, or timestamp C structure, and a value in the column was, respectively, an invalid date, time, or timestamp.

    (Function returns SQL_SUCCESS_WITH_INFO.)

  • SQLFetch, SQLFetchScroll

    A character column in the result set was bound to a date, time, or timestamp C structure, and a value in the column was, respectively, an invalid date, time, or timestamp.

    A character column in the result set was bound to a date, time, or timestamp C structure, and a value in the column was, respectively, an invalid date, time, or timestamp.

  • SQLGetData

    The character column in the result set was bound to a C date, time, or timestamp structure, and the value in the column was an invalid date, time, or timestamp, respectively. For more information, see Appendix D: Data Types .

  • SQLNativeSql

    *InStatementText contained an escape clause with an invalid date, time, or timestamp value.

  • SQLParamData
  • SQLPutData

    The data sent for a parameter or column that was bound to a date, time, or timestamp structure was, respectively, an invalid date, time, or timestamp.

    An input/output or output parameter was bound to a date, time, or timestamp C structure, and a value in the returned parameter was, respectively, an invalid date, time, or timestamp. (Function returns SQL_SUCCESS_WITH_INFO.)

  • SQLSetPos

    The argument Operation was SQL_UPDATE, and the assignment of a date or timestamp value to a column in the result set caused the year, month, or day field to be out of range.

    The argument Operation was SQL_REFRESH, and returning the date or timestamp value for one or more bound columns would have caused the year, month, or day field to be out of range.

22008Datetime field overflow
  • SQLBulkOperations

    The Operation argument was SQL_ADD or SQL_UPDATE_BY_BOOKMARK, and the performance of datetime arithmetic on data being sent to a column in the result set resulted in a datetime field (the year, month, day, hour, minute, or second field) of the result falling outside the permissible range of values for the field or being invalid based on the Gregorian calendar's natural rules for datetimes.

    The Operation argument was SQL_FETCH_BY_BOOKMARK, and the performance of datetime arithmetic on data being retrieved from the result set resulted in a datetime field (the year, month, day, hour, minute, or second field) of the result falling outside the permissible range of values for the field or being invalid based on the Gregorian calendar's natural rules for datetimes.

  • SQLExecDirect

    *StatementText contained an SQL statement that contained a datetime expression that, when computed, resulted in a date, time, or timestamp structure that was invalid.

    A datetime expression computed for an input/output or output parameter resulted in a date, time, or timestamp C structure that was invalid.

  • SQLExecute

    The prepared statement associated with the StatementHandle contained an SQL statement that contained a datetime expression that, when computed, resulted in a date, time, or timestamp structure that was invalid.

    A datetime expression computed for an input/output or output parameter resulted in a date, time, or timestamp C structure that was invalid.

  • SQLParamData
  • SQLPutData

    A datetime expression computed for an input/output or output parameter resulted in a date, time, or timestamp C structure that was invalid.

  • SQLSetPos

    The Operation argument was SQL_UPDATE, and the performance of datetime arithmetic on data being sent to a column in the result set resulted in a datetime field (the year, month, day, hour, minute, or second field) of the result being outside the permissible range of values for the field, or being invalid based on the Gregorian calendar's natural rules for datetimes.

    The Operation argument was SQL_REFRESH, and the performance of datetime arithmetic on data being retrieved from the result set resulted in a datetime field (the year, month, day, hour, minute, or second field) of the result being outside the permissible range of values for the field, or being invalid based on the Gregorian calendar's natural rules for datetimes.

22012Division by zero
  • SQLExecDirect

    *StatementText contained an SQL statement that contained an arithmetic expression that caused division by zero.

    An arithmetic expression calculated for an input/output or output parameter resulted in division by zero.

  • SQLExecute

    The prepared statement associated with the StatementHandle contained an arithmetic expression that caused division by zero.

    An arithmetic expression calculated for an input/output or output parameter resulted in division by zero.

  • SQLExtendedFetch

    A value from an arithmetic expression was returned, which resulted in division by zero.

    (Function returns SQL_SUCCESS_WITH_INFO.)

  • SQLFetch, SQLFetchScroll

    A value from an arithmetic expression was returned, which resulted in division by zero.

  • SQLGetData

    A value from an arithmetic expression that resulted in division by zero was returned.

  • SQLParamData
  • SQLPutData

    An arithmetic expression calculated for an input/output or output parameter resulted in division by zero.

22015Interval field overflow
  • SQLBulkOperations

    The Operation argument was SQL_ADD or SQL_UPDATE_BY_BOOKMARK, and the assignment of an exact numeric or interval C type to an interval SQL data type caused a loss of significant digits.

    The Operation argument was SQL_ADD or SQL_UPDATE_BY_BOOKMARK; when assigning to an interval SQL type, there was no representation of the value of the C type in the interval SQL type.

    The Operation argument was SQL_FETCH_BY_BOOKMARK, and assigning from an exact numeric or interval SQL type to an interval C type caused a loss of significant digits in the leading field.

    The Operation argument was SQL_FETCH_BY_BOOKMARK; when assigning to an interval C type, there was no representation of the value of the SQL type in the interval C type.

  • SQLExecDirect, SQLExecute

    *StatementText contained an exact numeric or interval parameter that, when converted to an interval SQL data type, caused a loss of significant digits.

    *StatementText contained an interval parameter with more than one field that, when converted to a numeric data type in a column, had no representation in the numeric data type.

    *StatementText contained parameter data that was assigned to an interval SQL type, and there was no representation of the value of the C type in the interval SQL type.

    Assigning an input/output or output parameter that was an exact numeric or interval SQL type to an interval C type caused a loss of significant digits.

    When an input/output or output parameter was assigned to an interval C structure, there was no representation of the data in the interval data structure.

  • SQLExtendedFetch

    Assigning from an exact numeric or interval SQL type to an interval C type caused a loss of significant digits in the leading field.

    When fetching data to an interval C type, there was no representation of the value of the SQL type in the interval C type.

    (Function returns SQL_SUCCESS_WITH_INFO.)

  • SQLFetch, SQLFetchScroll, SQLGetData

    Assigning from an exact numeric or interval SQL type to an interval C type caused a loss of significant digits in the leading field.

    When fetching data to an interval C type, there was no representation of the value of the SQL type in the interval C type.

  • SQLParamData
  • SQLPutData

    The data sent for an exact numeric or interval column or parameter to an interval SQL data type caused a loss of significant digits.

    Data was sent for an interval column or parameter with more than one field, was converted to a numeric data type, and had no representation in the numeric data type.

    The data sent for column or parameter data was assigned to an interval SQL type, and there was no representation of the value of the C type in the interval SQL type.

    The data sent for an exact numeric or interval C column or parameter to an interval C type caused a loss of significant digits.

    The data sent for column or parameter data was assigned to an interval C structure, and there was no representation of the data in the interval data structure.

  • SQLSetPos

    The Operation argument was SQL_UPDATE, and the assignment of an exact numeric or interval C type to an interval SQL data type caused a loss of significant digits.

    The Operation argument was SQL_UPDATE; when assigning to an interval SQL type, there was no representation of the value of the C type in the interval SQL type.

    The Operation argument was SQL_REFRESH, and assigning from an exact numeric or interval SQL type to an interval C type caused a loss of significant digits in the leading field.

    The Operation argument was SQL_REFRESH; when assigning to an interval C type, there was no representation of the value of the SQL type in the interval C type.

22018Invalid character value for cast specification
  • SQLBulkOperations

    The Operation argument was SQL_FETCH_BY_BOOKMARK; the C type was an exact or approximate numeric, a datetime, or an interval data type; the SQL type of the column was a character data type; and the value in the column was not a valid literal of the bound C type.

    The argument Operation was SQL_ADD or SQL_UPDATE_BY_BOOKMARK; the SQL type was an exact or approximate numeric, a datetime, or an interval data type; the C type was SQL_C_CHAR; and the value in the column was not a valid literal of the bound SQL type.

  • SQLExecDirect, SQLExecute

    *StatementText contained a C type that was an exact or approximate numeric, a datetime, or an interval data type; the SQL type of the column was a character data type; and the value in the column was not a valid literal of the bound C type.

    When an input/output or output parameter was returned, the SQL type was an exact or approximate numeric, a datetime, or an interval data type; the C type was SQL_C_CHAR; and the value in the column was not a valid literal of the bound SQL type.

  • SQLExtendedFetch

    The C type was an exact or approximate numeric, a datetime, or an interval data type; the SQL type of the column was a character data type; and the value in the column was not a valid literal of the bound C type.

    (Function returns SQL_SUCCESS_WITH_INFO.)

  • SQLFetch, SQLFetchScroll, SQLGetData

    A character column in the result set was bound to a character C buffer, and the column contained a character for which there was no representation in the character set of the buffer.

    The C type was an exact or approximate numeric, a datetime, or an interval data type; the SQL type of the column was a character data type; and the value in the column was not a valid literal of the bound C type.

  • SQLParamData
  • SQLPrepare

    *StatementText contained an SQL statement that contained a literal or parameter, and the value was incompatible with the data type of the associated table column.

  • SQLPutData

    The C type was an exact or approximate numeric, a datetime, or an interval data type; the SQL type of the column was a character data type; and the value in the column or parameter was not a valid literal of the bound C type.

    The SQL type was an exact or approximate numeric, a datetime, or an interval data type; the C type was SQL_C_CHAR; and the value in the column or parameter was not a valid literal of the bound SQL type.

  • SQLSetPos

    The Operation argument was SQL_REFRESH; the C type was an exact or approximate numeric, a datetime, or an interval data type; the SQL type of the column was a character data type; and the value in the column was not a valid literal of the bound C type.

    The argument Operation was SQL_UPDATE; the SQL type was an exact or approximate numeric, a datetime, or an interval data type; the C type was SQL_C_CHAR; and the value in the column was not a valid literal

22019Invalid escape character
  • SQLExecDirect

    *StatementText contained an SQL statement that contained a LIKE predicate with an ESCAPE in the WHERE clause, and the length of the escape character following ESCAPE was not equal to 1.

  • SQLExecute

    The prepared statement associated with StatementHandle contained a LIKE predicate with an ESCAPE in the WHERE clause, and the length of the escape character following ESCAPE was not equal to 1.

  • SQLPrepare

    The argument StatementText contained a LIKE predicate with an ESCAPE in the WHERE clause, and the length of the escape character following ESCAPE was not equal to 1.

22025Invalid escape sequence
  • SQLExecDirect

    *StatementText contained an SQL statement that contained "LIKE pattern value ESCAPE escape character" in the WHERE clause, and the character following the escape character in the pattern value was not one of "%" or "_".

  • SQLExecute

    The prepared statement associated with StatementHandle contained "LIKE pattern value ESCAPE escape character" in the WHERE clause, and the character following the escape character in the pattern value was not one of "%" or "_".

  • SQLPrepare

    The argument StatementText contained "LIKE pattern value ESCAPE escape character" in the WHERE clause, and the character following the escape character in the pattern value was neither "%" nor "_".

22026String data, length mismatch
  • SQLParamData

    The SQL_NEED_LONG_DATA_LEN information type in SQLGetInfo was "Y", and less data was sent for a long parameter (the data type was SQL_LONGVARCHAR, SQL_LONGVARBINARY, or a long data source-specific data type) than was specified with the StrLen_or_IndPtr argument in SQLBindParameter.

    The SQL_NEED_LONG_DATA_LEN information type in SQLGetInfo was "Y", and less data was sent for a long column (the data type was SQL_LONGVARCHAR, SQL_LONGVARBINARY, or a long data source�specific data type) than was specified in the length buffer corresponding to a column in a row of data that was added or updated with SQLBulkOperations or updated with SQLSetPos.

Download ODBC Drivers for Oracle, SQL Server, Firebird, ISAM, InterBase, Sybase, MS Access and more.

SQLSTATE 23

SQLSTATEErrorCan be returned from
23000Integrity constraint violation
  • SQLBulkOperations

    The Operation argument was SQL_ADD, SQL_DELETE_BY_BOOKMARK, or SQL_UPDATE_BY_BOOKMARK, and an integrity constraint was violated.

    The Operation argument was SQL_ADD, and a column that was not bound is defined as NOT NULL and has no default.

    The Operation argument was SQL_ADD, the length specified in the bound StrLen_or_IndPtr buffer was SQL_COLUMN_IGNORE, and the column did not have a default value.

  • SQLExecDirect

    *StatementText contained an SQL statement that contained a parameter or literal. The parameter value was NULL for a column defined as NOT NULL in the associated table column, a duplicate value was supplied for a column constrained to contain only unique values, or some other integrity constraint was violated.

  • SQLExecute

    The prepared statement associated with the StatementHandle contained a parameter. The parameter value was NULL for a column defined as NOT NULL in the associated table column, a duplicate value was supplied for a column constrained to contain only unique values, or some other integrity constraint was violated.

  • SQLParamData
  • SQLSetPos

    The argument Operation was SQL_DELETE or SQL_UPDATE, and an integrity constraint was violated.

Download ODBC Drivers for Oracle, SQL Server, Firebird, ISAM, InterBase, Sybase, MS Access and more.

SQLSTATE 24

SQLSTATEErrorCan be returned from
24000Invalid cursor state
  • SQLBulkOperations

    The StatementHandle was in an executed state, but no result set was associated with the StatementHandle.

  • SQLCloseCursor

    No cursor was open on the StatementHandle. (This is returned only by an ODBC 3.x driver.)

  • SQLColumnPrivileges, SQLColumns, SQLForeignKeys

    A cursor was open on the StatementHandle, and SQLFetch or SQLFetchScroll had been called. This error is returned by the Driver Manager if SQLFetch or SQLFetchScroll has not returned SQL_NO_DATA, and is returned by the driver if SQLFetch or SQLFetchScroll has returned SQL_NO_DATA.

    A cursor was open on the StatementHandle, but SQLFetch or SQLFetchScroll had not been called.

  • SQLExecDirect

    A cursor was positioned on the StatementHandle by SQLFetch or SQLFetchScroll This error is returned by the Driver Manager if SQLFetch or SQLFetchScroll has not returned SQL_NO_DATA, and is returned by the driver if SQLFetch or SQLFetchScroll has returned SQL_NO_DATA.

    A cursor was open but not positioned on the StatementHandle.

    *StatementText contained a positioned update or delete statement, and the cursor was positioned before the start of the result set or after the end of the result set.

  • SQLExecute

    A cursor was positioned on the StatementHandle by SQLFetch or SQLFetchScroll. This error is returned by the Driver Manager if SQLFetch or SQLFetchScroll has not returned SQL_NO_DATA, and is returned by the driver if SQLFetch or SQLFetchScroll has returned SQL_NO_DATA.

    A cursor was open on the StatementHandle.

    The prepared statement associated with the StatementHandle contained a positioned update or delete statement and the cursor was positioned before the start of the result set or after the end of the result set.

  • SQLExtendedFetch, SQLFetch, SQLFetchScroll

    The StatementHandle was in an executed state, but no result set was associated with the StatementHandle.

  • SQLGetData

    (DM) The function was called without first calling SQLFetch or SQLFetchScroll to position the cursor on the row of data required.

    (DM) The StatementHandle was in an executed state, but no result set was associated with the StatementHandle.

    A cursor was open on the StatementHandle and SQLFetch or SQLFetchScroll had been called, but the cursor was positioned before the start of the result set or after the end of the result set.

  • SQLGetStmtAttr

    The argument Attribute was SQL_ATTR_ROW_NUMBER and the cursor was not open, or the cursor was positioned before the start of the result set or after the end of the result set.

  • SQLGetTypeInfo, SQLProcedureColumns, SQLProcedures, SQLSpecialColumns, SQLStatistics, SQLTablePrivileges, SQLTables

    A cursor was open on the StatementHandle, and SQLFetch or SQLFetchScroll had been called. This error is returned by the Driver Manager if SQLFetch or SQLFetchScroll has not returned SQL_NO_DATA, and is returned by the driver if SQLFetch or SQLFetchScroll has returned SQL_NO_DATA.

    A result set was open on the StatementHandle, but SQLFetch or SQLFetchScroll had not been called.

  • SQLNativeSql

    The cursor referred to in the statement was positioned before the start of the result set or after the end of the result set. This error may not be returned by a driver having a native DBMS cursor implementation.

  • SQLPrepare, SQLPrimaryKeys

    (DM) A cursor was open on the StatementHandle, and SQLFetch or SQLFetchScroll had been called.

    A cursor was open on the StatementHandle, but SQLFetch or SQLFetchScroll had not been called.

  • SQLSetConnectAttr

    The Attribute argument was SQL_ATTR_CURRENT_CATALOG, and a result set was pending.

  • SQLSetCursorName

    The statement corresponding to StatementHandle was already in an executed or cursor-positioned state.

  • SQLSetPos

    The StatementHandle was in an executed state, but no result set was associated with the StatementHandle.

    (DM) A cursor was open on the StatementHandle, but SQLFetch or SQLFetchScroll had not been called.

    A cursor was open on the StatementHandle, and SQLFetch or SQLFetchScroll had been called, but the cursor was positioned before the start of the result set or after the end of the result set.

    The argument Operation was SQL_DELETE, SQL_REFRESH, or SQL_UPDATE, and the cursor was positioned before the start of the result set or after the end of the result set.

  • SQLSetStmtAttr

    The Attribute was SQL_ATTR_CONCURRENCY, SQL_ATTR_CURSOR_TYPE, SQL_ATTR_SIMULATE_CURSOR, or SQL_ATTR_USE_BOOKMARKS, and the cursor was open.

Download ODBC Drivers for Oracle, SQL Server, Firebird, ISAM, InterBase, Sybase, MS Access and more.

SQLSTATE 25

SQLSTATEErrorCan be returned from
25000Invalid transaction state
  • SQLDisconnect

    There was a transaction in process on the connection specified by the argument ConnectionHandle. The transaction remains active.

25S01Transaction state
  • SQLEndTran

    One or more of the connections in Handle failed to complete the transaction with the outcome specified, and the outcome is unknown.

25S02Transaction is still active
  • SQLEndTran

    The driver was not able to guarantee that all work in the global transaction could be completed atomically, and the transaction is still active.

25S03Transaction is rolled back
  • SQLEndTran

    The driver was not able to guarantee that all work in the global transaction could be completed atomically, and all work in the transaction active in Handle was rolled back.

Download ODBC Drivers for Oracle, SQL Server, Firebird, ISAM, InterBase, Sybase, MS Access and more.

SQLSTATE 28

SQLSTATEErrorCan be returned from
28000Invalid authorization specification
  • SQLBrowseConnect

    Either the user identifier or the authorization string or both, as specified in the browse request connection string (InConnectionString), violated restrictions defined by the data source.

  • SQLConnect

    The value specified for the argument UserName or the value specified for the argument Authentication violated restrictions defined by the data source.

  • SQLDriverConnect

    Either the user identifier or the authorization string, or both, as specified in the connection string (InConnectionString), violated restrictions defined by the data source.

Download ODBC Drivers for Oracle, SQL Server, Firebird, ISAM, InterBase, Sybase, MS Access and more.

SQLSTATE 34

SQLSTATEErrorCan be returned from
34000Invalid cursor name
  • SQLExecDirect

    *StatementText contained a positioned update or delete statement, and the cursor referenced by the statement being executed was not open.

  • SQLPrepare

    *StatementText contained a positioned DELETE or a positioned UPDATE, and the cursor referenced by the statement being prepared was not open.

  • SQLSetCursorName

    The cursor name specified in *CursorName was invalid because it exceeded the maximum length as defined by the driver, or it started with "SQLCUR" or "SQL_CUR."

Download ODBC Drivers for Oracle, SQL Server, Firebird, ISAM, InterBase, Sybase, MS Access and more.

SQLSTATE 3C

SQLSTATEErrorCan be returned from
3C000Duplicate cursor name

Download ODBC Drivers for Oracle, SQL Server, Firebird, ISAM, InterBase, Sybase, MS Access and more.

SQLSTATE 3D

SQLSTATEErrorCan be returned from
3D000Invalid catalog name

Download ODBC Drivers for Oracle, SQL Server, Firebird, ISAM, InterBase, Sybase, MS Access and more.

SQLSTATE 3F

SQLSTATEErrorCan be returned from
3F000Invalid schema name

Download ODBC Drivers for Oracle, SQL Server, Firebird, ISAM, InterBase, Sybase, MS Access and more.

SQLSTATE 40

SQLSTATEErrorCan be returned from
40001Serialization failure
40002Integrity constraint violation
  • SQLEndTran

    The CompletionType was SQL_COMMIT, and the commitment of changes caused integrity constraint violation. As a result, the transaction was rolled back.

40003Statement completion unknown

Download ODBC Drivers for Oracle, SQL Server, Firebird, ISAM, InterBase, Sybase, MS Access and more.

SQLSTATE 42

SQLSTATEErrorCan be returned from
42000Syntax error or access violation
  • SQLBulkOperations

    The driver was unable to lock the row as needed to perform the operation requested in the Operation argument.

  • SQLExecDirect

    *StatementText contained an SQL statement that was not preparable or contained a syntax error.

    The user did not have permission to execute the SQL statement contained in *StatementText.

  • SQLExecute

    The user did not have permission to execute the prepared statement associated with the StatementHandle.

  • SQLParamData
  • SQLPrepare

    *StatementText contained an SQL statement that was not preparable or contained a syntax error.

    *StatementText contained a statement for which the user did not have the required privileges.

  • SQLSetPos

    The driver was unable to lock the row as needed to perform the operation requested in the argument Operation.

    The driver was unable to lock the row as requested in the argument LockType.

42S01Base table or view already exists
  • SQLExecDirect, SQLPrepare

    *StatementText contained a CREATE TABLE or CREATE VIEW statement, and the table name or view name specified already exists.

42S02Base table or view not found
  • SQLExecDirect

    *StatementText contained a DROP TABLE or a DROP VIEW statement, and the specified table name or view name did not exist.

    *StatementText contained an ALTER TABLE statement, and the specified table name did not exist.

    *StatementText contained a CREATE VIEW statement, and a table name or view name defined by the query specification did not exist.

    *StatementText contained a CREATE INDEX statement, and the specified table name did not exist.

    *StatementText contained a GRANT or REVOKE statement, and the specified table name or view name did not exist.

    *StatementText contained a SELECT statement, and a specified table name or view name did not exist.

    *StatementText contained a DELETE, INSERT, or UPDATE statement, and the specified table name did not exist.

    *StatementText contained a CREATE TABLE statement, and a table specified in a constraint (referencing a table other than the one being created) did not exist.

    *StatementText contained a CREATE SCHEMA statement, and a specified table name or view name did not exist.

  • SQLPrepare

    *StatementText contained a DROP TABLE or a DROP VIEW statement, and the specified table name or view name did not exist.

    *StatementText contained an ALTER TABLE statement, and the specified table name did not exist.

    *StatementText contained a CREATE VIEW statement, and a table name or view name defined by the query specification did not exist.

    *StatementText contained a CREATE INDEX statement, and the specified table name did not exist.

    *StatementText contained a GRANT or REVOKE statement, and the specified table name or view name did not exist.

    *StatementText contained a SELECT statement, and a specified table name or view name did not exist.

    *StatementText contained a DELETE, INSERT, or UPDATE statement, and the specified table name did not exist.

    *StatementText contained a CREATE TABLE statement, and a table specified in a constraint (referencing a table other than the one being created) did not exist.

42S11Index already exists
  • SQLExecDirect

    *StatementText contained a CREATE INDEX statement, and the specified index name already existed.

    *StatementText contained a CREATE SCHEMA statement, and the specified index name already existed.

  • SQLPrepare

    *StatementText contained a CREATE INDEX statement, and the specified index name already existed.

42S12Index not found
  • SQLExecDirect, SQLPrepare

    *StatementText contained a DROP INDEX statement, and the specified index name did not exist.

42S21Column already exists
  • SQLExecDirect

    *StatementText contained an ALTER TABLE statement, and the column specified in the ADD clause is not unique or identifies an existing column in the base table.

  • SQLPrepare

    *StatementText contained an ALTER TABLE statement, and the column specified in the ADD clause is not unique or identifies an existing column in the base table.

42S22Column not found
  • SQLExecDirect

    *StatementText contained a CREATE INDEX statement, and one or more of the column names specified in the column list did not exist.

    *StatementText contained a GRANT or REVOKE statement, and a specified column name did not exist.

    *StatementText contained a SELECT, DELETE, INSERT, or UPDATE statement, and a specified column name did not exist.

    *StatementText contained a CREATE TABLE statement, and a column specified in a constraint (referencing a table other than the one being created) did not exist.

    *StatementText contained a CREATE SCHEMA statement, and a specified column name did not exist.

  • SQLPrepare

    *StatementText contained a CREATE INDEX statement, and one or more of the column names specified in the column list did not exist.

    *StatementText contained a GRANT or REVOKE statement, and a specified column name did not exist.

    *StatementText contained a SELECT, DELETE, INSERT, or UPDATE statement, and a specified column name did not exist.

    *StatementText contained a CREATE TABLE statement, and a column specified in a constraint (referencing a table other than the one being created) did not exist.

Download ODBC Drivers for Oracle, SQL Server, Firebird, ISAM, InterBase, Sybase, MS Access and more.

SQLSTATE 44

SQLSTATEErrorCan be returned from
44000WITH CHECK OPTION violation
  • SQLBulkOperations

    The Operation argument was SQL_ADD or SQL_UPDATE_BY_BOOKMARK, and the insert or update was performed on a viewed table (or a table derived from the viewed table) that was created by specifying WITH CHECK OPTION, such that one or more rows affected by the insert or update will no longer be present in the viewed table.

  • SQLExecDirect

    The argument StatementText contained an INSERT statement performed on a viewed table or a table derived from the viewed table that was created by specifying WITH CHECK OPTION, such that one or more rows affected by the INSERT statement will no longer be present in the viewed table.

    The argument StatementText contained an UPDATE statement performed on a viewed table or a table derived from the viewed table that was created by specifying WITH CHECK OPTION, such that one or more rows affected by the UPDATE statement will no longer be present in the viewed table.

  • SQLExecute

    The prepared statement associated with StatementHandle contained an INSERT statement performed on a viewed table or a table derived from the viewed table that was created by specifying WITH CHECK OPTION, such that one or more rows affected by the INSERT statement will no longer be present in the viewed table.

    The prepared statement associated with the StatementHandle contained an UPDATE statement performed on a viewed table or a table derived from the viewed table that was created by specifying WITH CHECK OPTION, such that one or more rows affected by the UPDATE statement will no longer be present in the viewed table.

  • SQLParamData
  • SQLSetPos

    The Operation argument was SQL_UPDATE, and the update was performed on a viewed table or a table derived from the viewed table which was created by specifying WITH CHECK OPTION, such that one or more rows affected by the update will no longer be present in the viewed table.

Download ODBC Drivers for Oracle, SQL Server, Firebird, ISAM, InterBase, Sybase, MS Access and more.

SQLSTATE HY

SQLSTATEErrorCan be returned from
HY000General error
  • An error occurred for which there was no specific SQLSTATE and for which no implementation-specific SQLSTATE was defined. The error message returned by SQLGetDiagRec in the *MessageText buffer describes the error and its cause.
  • All ODBC functions except:

    SQLError

    SQLGetDiagField

    SQLGetDiagRec

HY001Memory allocation error
HY003Invalid application buffer type
  • SQLBindCol

    The argument TargetType was neither a valid data type nor SQL_C_DEFAULT.

  • SQLBindParameter

    The value specified by the argument ValueType was not a valid C data type or SQL_C_DEFAULT.

  • SQLGetData

    (DM) The argument TargetType was neither a valid data type, SQL_C_DEFAULT, nor SQL_ARD_TYPE.

    (DM) The argument ColumnNumber was 0, and the argument TargetType was not SQL_C_BOOKMARK for a fixed-length bookmark or SQL_C_VARBOOKMARK for a variable-length bookmark.

HY004Invalid SQL data type
  • SQLBindParameter

    The value specified for the argument ParameterType was neither a valid ODBC SQL data type identifier nor a driver-specific SQL data type identifier supported by the driver.

  • SQLGetTypeInfo

    The value specified for the argument DataType was neither a valid ODBC SQL data type identifier nor a driver-specific data type identifier supported by the driver.

HY007Associated statement is not prepared
  • SQLCopyDesc

    SourceDescHandle was associated with an IRD, and the associated statement handle was not in the prepared or executed state.

  • SQLGetDescField

    DescriptorHandle was associated with a StatementHandle as an IRD, and the associated statement handle had not been prepared or executed.

  • SQLGetDescRec

    DescriptorHandle was associated with an IRD, and the associated statement handle was not in the prepared or executed state.

HY008Operation cancelled
HY009Invalid use of null pointer
  • SQLAllocHandle

    (DM) The OutputHandlePtr argument was a null pointer.

  • SQLBindParameter

    (DM) The argument ParameterValuePtr was a null pointer, the argument StrLen_or_IndPtr was a null pointer, and the argument InputOutputType was not SQL_PARAM_OUTPUT.

    (DM) SQL_PARAM_OUTPUT, where the argument ParameterValuePtr was a null pointer, the C type was char or binary, and the BufferLength (cbValueMax) was greater than 0.

  • SQLBulkOperations
  • SQLColumnPrivileges

    The TableName argument was a null pointer.

    The SQL_ATTR_METADATA_ID statement attribute was set to SQL_TRUE, the CatalogName argument was a null pointer, and the SQL_CATALOG_NAME InfoType returns that catalog names are supported.

    (DM) The SQL_ATTR_METADATA_ID statement attribute was set to SQL_TRUE, and the SchemaName or ColumnName argument was a null pointer.

  • SQLColumns

    The SQL_ATTR_METADATA_ID statement attribute was set to SQL_TRUE, the CatalogName argument was a null pointer, and the SQL_CATALOG_NAME InfoType returns that catalog names are supported.

    (DM) The SQL_ATTR_METADATA_ID statement attribute was set to SQL_TRUE, and the SchemaName, TableName, or ColumnName argument was a null pointer.

  • SQLExecDirect

    (DM) *StatementText was a null pointer.

  • SQLForeignKeys

    (DM) The arguments PKTableName and FKTableName were both null pointers.

    The SQL_ATTR_METADATA_ID statement attribute was set to SQL_TRUE, the FKCatalogName or PKCatalogName argument was a null pointer, and the SQL_CATALOG_NAME InfoType returns that catalog names are supported.

    (DM) The SQL_ATTR_METADATA_ID statement attribute was set to SQL_TRUE, and the FKSchemaName, PKSchemaName, FKTableName, or PKTableName argument was a null pointer.

  • SQLGetCursorName
  • SQLGetData

    (DM) The argument CursorNamewas a null pointer.

  • SQLGetFunctions
  • SQLNativeSql

    (DM) *InStatementText was a null pointer.

  • SQLPrepare

    (DM) StatementText was a null pointer.

  • SQLPrimaryKeys

    (DM) The TableName argument was a null pointer.

    The SQL_ATTR_METADATA_ID statement attribute was set to SQL_TRUE, the CatalogName argument was a null pointer, and SQLGetInfo with the SQL_CATALOG_NAME information type returns that catalog names are supported.

    (DM) The SQL_ATTR_METADATA_ID statement attribute was set to SQL_TRUE, and the SchemaName argument was a null pointer.

  • SQLProcedureColumns

    The SQL_ATTR_METADATA_ID statement attribute was set to SQL_TRUE, the CatalogName argument was a null pointer, and the SQL_CATALOG_NAME InfoType returns that catalog names are supported.

    (DM) The SQL_ATTR_METADATA_ID statement attribute was set to SQL_TRUE, and the SchemaName, ProcName, or ColumnName argument was a null pointer.

  • SQLProcedures

    The SQL_ATTR_METADATA_ID statement attribute was set to SQL_TRUE, the CatalogName argument was a null pointer, and the SQL_CATALOG_NAME InfoType returns that catalog names are supported.

    (DM) The SQL_ATTR_METADATA_ID statement attribute was set to SQL_TRUE, and the SchemaNameor ProcName argument was a null pointer.

  • SQLPutData

    (DM) The argument DataPtr was a null pointer, and the argument StrLen_or_Ind was not 0, SQL_DEFAULT_PARAM, or SQL_NULL_DATA.

  • SQLSetConnectAttr

    The Attribute argument identified a connection attribute that required a string value, and the ValuePtrargument was a null pointer.

  • SQLSetCursorName

    (DM) The argument CursorName was a null pointer.

  • SQLSetEnvAttr

    The Attribute argument identified an environment attribute that required a string value, and the ValuePtr argument was a null pointer.

  • SQLSetStmtAttr

    The Attribute argument identified a statement attribute that required a string attribute, and the ValuePtrargument was a null pointer.

  • SQLSpecialColumns, SQLStatistics, SQLTablePrivileges, SQLTables

    The TableName argument was a null pointer.

    The SQL_ATTR_METADATA_ID statement attribute was set to SQL_TRUE, the CatalogName argument was a null pointer, and the SQL_CATALOG_NAME InfoType returns that catalog names are supported.

    (DM) The SQL_ATTR_METADATA_ID statement attribute was set to SQL_TRUE, and the SchemaName argument was a null pointer.

HY010Function sequence error
HY011Attribute cannot be set now
HY012Invalid transaction operation code
  • SQLEndTran

    (DM) The value specified for the argument CompletionType was neither SQL_COMMIT nor SQL_ROLLBACK.

HY013Memory management error
HY014Limit on the number of handles exceeded
  • SQLAllocHandle

    The driver-defined limit for the number of handles that can be allocated for the type of handle indicated by the HandleType argument has been reached.

HY015No cursor name available
HY016Cannot modify an implementation row descriptor
  • SQLCopyDesc

    TargetDescHandle was associated with an IRD.

  • SQLSetDescField

    The DescriptorHandle argument was associated with an IRD, and the FieldIdentifier argument was not SQL_DESC_ARRAY_STATUS_PTR or SQL_DESC_ROWS_PROCESSED_PTR.

  • SQLSetDescRec

    The DescriptorHandle argument was associated with an IRD.

HY017Invalid use of an automatically allocated descriptor handle
  • SQLFreeHandle

    (DM) The Handle argument was set to the handle for an automatically allocated descriptor.

  • SQLSetStmtAttr

    (DM) The Attribute argument was SQL_ATTR_IMP_ROW_DESC or SQL_ATTR_IMP_PARAM_DESC.

    (DM) The Attribute argument was SQL_ATTR_APP_ROW_DESC or SQL_ATTR_APP_PARAM_DESC, and the value in ValuePtr was an implicitly allocated descriptor handle other than the handle originally allocated for the ARD or APD.

HY018Server declined cancel request
  • SQLCancel

    The server declined the cancel request.

HY019Non-character and non-binary data sent in pieces
  • SQLPutData

    SQLPutData was called more than once for a parameter or column, and it was not being used to send character C data to a column with a character, binary, or data source-specific data type or to send binary C data to a column with a character, binary, or data source-specific data type.

HY020Attempt to concatenate a null value
  • SQLPutData

    SQLPutData was called more than once since the call that returned SQL_NEED_DATA, and in one of those calls, the StrLen_or_Ind argument contained SQL_NULL_DATA or SQL_DEFAULT_PARAM.

HY021Inconsistent descriptor information
  • SQLBindParameter

    The descriptor information checked during a consistency check was not consistent. (See the "Consistency Checks" section in SQLSetDescField.)

    The value specified for the argument DecimalDigits was outside the range of values supported by the data source for a column of the SQL data type specified by the ParameterType argument.

  • SQLCopyDesc

    The descriptor information checked during a consistency check was not consistent. For more information, see "Consistency Checks" in SQLSetDescField.

  • SQLGetDescField

    The SQL_DESC_TYPE and SQL_DESC_DATETIME_INTERVAL_CODE fields do not form a valid ODBC SQL type, a valid driver-specific SQL type (for IPDs), or a valid ODBC C type (for APDs or ARDs).

  • SQLSetDescField

    The SQL_DESC_TYPE and SQL_DESC_DATETIME_INTERVAL_CODE fields do not form a valid ODBC SQL type or a valid driver-specific SQL type (for IPDs) or a valid ODBC C type (for APDs or ARDs).

    Descriptor information checked during a consistency check was not consistent. (See "Consistency Check" in SQLSetDescRec.)

  • SQLSetDescRec

    The Type field, or any other field associated with the SQL_DESC_TYPE field in the descriptor, was not valid or consistent. Descriptor information checked during a consistency check was not consistent. (See "Consistency Checks," later in this section.)

HY024Invalid attribute value
  • SQLGetInfo

    (DM) The InfoType argument was SQL_DRIVER_HSTMT, and the value pointed to by InfoValuePtr was not a valid statement handle.

  • SQLSetConnectAttr

    Given the specified Attribute value, an invalid value was specified in ValuePtr. (The Driver Manager returns this SQLSTATE only for connection and statement attributes that accept a discrete set of values, such as SQL_ATTR_ACCESS_MODE or SQL_ATTR_ASYNC_ENABLE. For all other connection and statement attributes, the driver must verify the value specified in ValuePtr.)

    The Attribute argument was SQL_ATTR_TRACEFILE or SQL_ATTR_TRANSLATE_LIB, and ValuePtr was an empty string.

  • SQLSetEnvAttr

    Given the specified Attribute value, an invalid value was specified in ValuePtr.

  • SQLSetStmtAttr

    Given the specified Attribute value, an invalid value was specified in ValuePtr. (The Driver Manager returns this SQLSTATE only for connection and statement attributes that accept a discrete set of values, such as SQL_ATTR_ACCESS_MODE or SQL_ATTR_ASYNC_ENABLE. For all other connection and statement attributes, the driver must verify the value specified in ValuePtr.)

    The Attribute argument was SQL_ATTR_APP_ROW_DESC or SQL_ATTR_APP_PARAM_DESC, and ValuePtr was an explicitly allocated descriptor handle that is not on the same connection as the StatementHandle argument.

HY090Invalid string or buffer length
  • SQLBindCol

    (DM) The value specified for the argument BufferLength was less than 0.

    (DM) The driver was an ODBC 2.x driver, the ColumnNumber argument was set to 0, and the value specified for the argument BufferLength was not equal to 4.

  • SQLBindParameter

    (DM) The value in BufferLength was less than 0. (See the description of the SQL_DESC_DATA_PTR field in SQLSetDescField.)

  • SQLBrowseConnect

    (DM) The value specified for argument StringLength1 was less than 0 and was not equal to SQL_NTS.

    (DM) The value specified for argument BufferLength was less than 0.

  • SQLBulkOperations

    The Operation argument was SQL_ADD or SQL_UPDATE_BY_BOOKMARK; a data value was not a null pointer; the C data type was SQL_C_BINARY or SQL_C_CHAR; and the column length value was less than 0, but not equal to SQL_DATA_AT_EXEC, SQL_COLUMN_IGNORE, SQL_NTS, or SQL_NULL_DATA, or less than or equal to SQL_LEN_DATA_AT_EXEC_OFFSET.

    The value in a length/indicator buffer was SQL_DATA_AT_EXEC; the SQL type was either SQL_LONGVARCHAR, SQL_LONGVARBINARY, or a long data source-specific data type; and the SQL_NEED_LONG_DATA_LEN information type in SQLGetInfo was "Y".

    The Operation argument was SQL_ADD, the SQL_ATTR_USE_BOOKMARK statement attribute was set to SQL_UB_VARIABLE, and column 0 was bound to a buffer whose length was not equal to the maximum length for the bookmark for this result set. (This length is available in the SQL_DESC_OCTET_LENGTH field of the IRD and can be obtained by calling SQLDescribeCol, SQLColAttribute, or SQLGetDescField.)

  • SQLColAttribute

    (DM) *CharacterAttributePtr is a character string, and BufferLength was less than 0 but not equal to SQL_NTS.

  • SQLColumnPrivileges

    (DM) The value of one of the name length arguments was less than 0 but not equal to SQL_NTS.

    The value of one of the name length arguments exceeded the maximum length value for the corresponding name. (See "Comments.")

  • SQLColumns

    (DM) The value of one of the name length arguments was less than 0 but not equal to SQL_NTS.

    The value of one of the name length arguments exceeded the maximum length value for the corresponding catalog or name. The maximum length of each catalog or name may be obtained by calling SQLGetInfo with the InfoType values. (See "Comments.")

  • SQLConnect

    (DM) The value specified for argument NameLength1, NameLength2, or NameLength3was less than 0 but not equal to SQL_NTS.

    (DM) The value specified for argument NameLength1 exceeded the maximum length for a data source name.

  • SQLDataSources

    (DM) The value specified for argument BufferLength1 was less than 0.

    (DM) The value specified for argument BufferLength2 was less than 0.

  • SQLDescribeCol

    (DM) The value specified for argument BufferLength was less than 0.

  • SQLDriverConnect

    (DM) The value specified for argument StringLength1 was less than 0 and was not equal to SQL_NTS.

    (DM) The value specified for argument BufferLength was less than 0.

  • SQLDrivers

    (DM) The value specified for argument BufferLength1 was less than 0.

    (DM) The value specified for argument BufferLength2 was less than 0 or equal to 1.

  • SQLExecDirect

    (DM) The argument TextLength was less than or equal to 0 but not equal to SQL_NTS.

    A parameter value, set with SQLBindParameter, was a null pointer, and the parameter length value was not 0, SQL_NULL_DATA, SQL_DATA_AT_EXEC, SQL_DEFAULT_PARAM, or less than or equal to SQL_LEN_DATA_AT_EXEC_OFFSET.

    A parameter value, set with SQLBindParameter, was not a null pointer; the C data type was SQL_C_BINARY or SQL_C_CHAR; and the parameter length value was less than 0 but was not SQL_NTS, SQL_NULL_DATA, SQL_DATA_AT_EXEC, SQL_DEFAULT_PARAM, or less than or equal to SQL_LEN_DATA_AT_EXEC_OFFSET.

    A parameter length value bound by SQLBindParameter was set to SQL_DATA_AT_EXEC; the SQL type was either SQL_LONGVARCHAR, SQL_LONGVARBINARY, or a long data source-specific data type; and the SQL_NEED_LONG_DATA_LEN information type in SQLGetInfo was "Y".

  • SQLExecute

    A parameter value, set with SQLBindParameter, was a null pointer, and the parameter length value was not 0, SQL_NULL_DATA, SQL_DATA_AT_EXEC, SQL_DEFAULT_PARAM, or less than or equal to SQL_LEN_DATA_AT_EXEC_OFFSET.

    A parameter value, set with SQLBindParameter, was not a null pointer; the C data type was SQL_C_BINARY or SQL_C_CHAR; and the parameter length value was less than 0 but was not SQL_NTS, SQL_NULL_DATA, SQL_DEFAULT_PARAM, or SQL_DATA_AT_EXEC, or less than or equal to SQL_LEN_DATA_AT_EXEC_OFFSET.

    A parameter length value bound by SQLBindParameter was set to SQL_DATA_AT_EXEC; the SQL type was either SQL_LONGVARCHAR, SQL_LONGVARBINARY, or a long data source-specific data type; and the SQL_NEED_LONG_DATA_LEN information type in SQLGetInfo was "Y".

  • SQLFetch

    The SQL_ATTR_USE_BOOKMARK statement attribute was set to SQL_UB_VARIABLE, and column 0 was bound to a buffer whose length was not equal to the maximum length for the bookmark for this result set. (This length is available in the SQL_DESC_OCTET_LENGTH field of the IRD and can be obtained by calling SQLDescribeCol, SQLColAttribute, or SQLGetDescField.)

  • SQLFetchScroll

    The SQL_ATTR_USE_BOOKMARK statement attribute was set to SQL_UB_VARIABLE, and column 0 was bound to a buffer whose length was not equal to the maximum length for the bookmark for this result set. (This length is available in the SQL_DESC_OCTET_LENGTH field of the IRD and can be obtained by calling SQLDescribeCol, SQLColAttribute, or SQLGetDescField.)

  • SQLForeignKeys

    (DM) The value of one of the name length arguments was less than 0 but not equal to SQL_NTS.

    The value of one of the name length arguments exceeded the maximum length value for the corresponding name. (See "Comments.")

  • SQLGetConnectAttr

    (DM) *ValuePtr is a character string, and BufferLength was less than zero but not equal to SQL_NTS.

  • SQLGetCursorName

    (DM) The value specified in the argument BufferLength was less than 0.

  • SQLGetData

    (DM) The value specified for argument BufferLength was less than 0.

    The value specified for argument BufferLength was less than 4, the ColumnNumber argument was set to 0, and the driver was an ODBC 2.x driver.

  • SQLGetDescField

    (DM) *ValuePtr was a character string, and BufferLength was less than zero.

  • SQLGetInfo

    (DM) The value specified for argument BufferLength was less than 0.

    (DM) The value specified for BufferLength was an odd number, and *InfoValuePtrwas of a Unicode data type.

  • SQLGetStmtAttr

    (DM) *ValuePtr is a character string, and BufferLength was less than zero, but not equal to SQL_NTS.

  • SQLNativeSql

    (DM) The argument TextLength1 was less than 0, but not equal to SQL_NTS.

    (DM) The argument BufferLength was less than 0 and the argument OutStatementText was not a null pointer.

  • SQLParamData
  • SQLPrepare

    (DM) The argument TextLength was less than or equal to 0 but not equal to SQL_NTS.

  • SQLPrimaryKeys

    (DM) The value of one of the name length arguments was less than 0 but not equal to SQL_NTS, and the associated name argument is not a null pointer.

    The value of one of the name length arguments exceeded the maximum length value for the corresponding name.

  • SQLProcedureColumns

    (DM) The value of one of the name length arguments was less than 0 but not equal to SQL_NTS.

    The value of one of the name length arguments exceeded the maximum length value for the corresponding catalog, schema, procedure, or column name.

  • SQLProcedures

    (DM) The value of one of the name length arguments was less than 0 but not equal to SQL_NTS.

    The value of one of the name length arguments exceeded the maximum length value for the corresponding name.

  • SQLPutData

    The argument DataPtr was not a null pointer, and the argument StrLen_or_Ind was less than 0 but not equal to SQL_NTS or SQL_NULL_DATA.

  • SQLSetConnectAttr

    (DM) *ValuePtris a character string, and the StringLength argument was less than 0 but was not SQL_NTS.

  • SQLSetCursorName

    (DM) The argument NameLength was less than 0 but not equal to SQL_NTS.

  • SQLSetDescField

    (DM) *ValuePtr is a character string, and BufferLength was less than zero but was not equal to SQL_NTS.

    (DM) The driver was an ODBC 2.x driver, the descriptor was an ARD, the ColumnNumber argument was set to 0, and the value specified for the argument BufferLength was not equal to 4.

  • SQLSetDescRec

    (DM) The driver was an ODBC 2.x driver, the descriptor was an ARD, the ColumnNumber argument was set to 0, and the value specified for the argument BufferLength was not equal to 4.

  • SQLSetEnvAttr

    The StringLength argument was less than 0 but was not SQL_NTS.

  • SQLSetPos

    The Operation argument was SQL_UPDATE, a data value was a null pointer, and the column length value was not 0, SQL_DATA_AT_EXEC, SQL_COLUMN_IGNORE, SQL_NULL_DATA, or less than or equal to SQL_LEN_DATA_AT_EXEC_OFFSET.

    The Operation argument was SQL_UPDATE; a data value was not a null pointer; the C data type was SQL_C_BINARY or SQL_C_CHAR; and the column length value was less than 0 but not equal to SQL_DATA_AT_EXEC, SQL_COLUMN_IGNORE, SQL_NTS, or SQL_NULL_DATA, or less than or equal to SQL_LEN_DATA_AT_EXEC_OFFSET.

    The value in a length/indicator buffer was SQL_DATA_AT_EXEC; the SQL type was either SQL_LONGVARCHAR, SQL_LONGVARBINARY, or a long data source-specific data type; and the SQL_NEED_LONG_DATA_LEN information type in SQLGetInfo was "Y".

  • SQLSetStmtAttr

    (DM) *ValuePtr is a character string, and the StringLength argument was less than 0 but was not SQL_NTS.

  • SQLSpecialColumns

    (DM) The value of one of the length arguments was less than 0 but not equal to SQL_NTS.

    The value of one of the length arguments exceeded the maximum length value for the corresponding name. The maximum length of each name can be obtained by calling SQLGetInfo with the InfoType values: SQL_MAX_CATALOG_NAME_LEN, SQL_MAX_SCHEMA_NAME_LEN, or SQL_MAX_TABLE_NAME_LEN.

  • SQLStatistics

    (DM) The value of one of the name length arguments was less than 0 but not equal to SQL_NTS.

    The value of one of the name length arguments exceeded the maximum length value for the corresponding name.

  • SQLTablePrivileges

    (DM) The value of one of the name length arguments was less than 0 but not equal to SQL_NTS.

    The value of one of the name length arguments exceeded the maximum length value for the corresponding qualifier or name.

  • SQLTables

    (DM) The value of one of the length arguments was less than 0 but not equal to SQL_NTS.

    The value of one of the name length arguments exceeded the maximum length value for the corresponding name.

HY091Invalid descriptor field identifier
  • SQLColAttribute

    The value specified for the argument FieldIdentifier was not one of the defined values and was not an implementation-defined value.

  • SQLGetDescField

    FieldIdentifier was not an ODBC-defined field and was not an implementation-defined value.

    FieldIdentifier was undefined for the DescriptorHandle.

  • SQLSetDescField

    The value specified for the FieldIdentifier argument was not an ODBC-defined field and was not an implementation-defined value.

    The FieldIdentifier argument was invalid for the DescriptorHandle argument.

    The FieldIdentifier argument was a read-only, ODBC-defined field.

HY092Invalid attribute/option identifier
  • SQLAllocHandle

    (DM) The HandleType argument was not: SQL_HANDLE_ENV, SQL_HANDLE_DBC, SQL_HANDLE_STMT, or SQL_HANDLE_DESC.

  • SQLBulkOperations

    (DM) The value specified for the Operation argument was invalid.

    The Operation argument was SQL_ADD, SQL_UPDATE_BY_BOOKMARK, or SQL_DELETE_BY_BOOKMARK, and the SQL_ATTR_CONCURRENCY statement attribute was set to SQL_CONCUR_READ_ONLY.

    The Operation argument was SQL_DELETE_BY_BOOKMARK, SQL_FETCH_BY_BOOKMARK, or SQL_UPDATE_BY_BOOKMARK, and the bookmark column was not bound or the SQL_ATTR_USE_BOOKMARKS statement attribute was set to SQL_UB_OFF.

  • SQLCopyDesc

    The call to SQLCopyDesc prompted a call to SQLSetDescField, but *ValuePtr was not valid for the FieldIdentifier argument on TargetDescHandle.

  • SQLDriverConnect

    (DM) The DriverCompletion argument was SQL_DRIVER_PROMPT, and the WindowHandle argument was a null pointer.

  • SQLEndTran

    (DM) The value specified for the argument HandleType was neither SQL_HANDLE_ENV nor SQL_HANDLE_DBC.

  • SQLFreeStmt

    (DM) The value specified for the argument Option was not:
    SQL_CLOSE
    SQL_DROP
    SQL_UNBIND
    SQL_RESET_PARAMS

  • SQLGetConnectAttr, SQLGetEnvAttr, SQLGetStmtAttr

    The value specified for the argument Attribute was not valid for the version of ODBC supported by the driver.

  • SQLParamData
  • SQLSetConnectAttr

    (DM) The value specified for the argument Attribute was not valid for the version of ODBC supported by the driver.

    (DM) The value specified for the argument Attribute was a read-only attribute.

  • SQLSetDescField

    The value in *ValuePtr was not valid for the FieldIdentifier argument.

    The FieldIdentifier argument was SQL_DESC_UNNAMED, and ValuePtr was SQL_NAMED.

  • SQLSetEnvAttr

    (DM) The value specified for the argument Attribute was not valid for the version of ODBC supported by the driver.

  • SQLSetPos

    (DM) The value specified for the Operation argument was invalid.

    (DM) The value specified for the LockType argument was invalid.

    The Operation argument was SQL_UPDATE or SQL_DELETE, and the SQL_ATTR_CONCURRENCY statement attribute was SQL_ATTR_CONCUR_READ_ONLY.

  • SQLSetStmtAttr

    (DM) The value specified for the argument Attribute was not valid for the version of ODBC supported by the driver.

    (DM) The value specified for the argument Attribute was a read-only attribute.

HY095Function type out of range
HY096Invalid information type
  • SQLGetInfo

    The value specified for the argument InfoType was not valid for the version of ODBC supported by the driver.

HY097Column type out of range
HY098Scope type out of range
HY099Nullable type out of range
HY100Uniqueness option type out of range
HY101Accuracy option type out of range
HY103Invalid retrieval code
  • SQLDataSources

    (DM) The value specified for the argument Direction was not equal to SQL_FETCH_FIRST, SQL_FETCH_FIRST_USER, SQL_FETCH_FIRST_SYSTEM, or SQL_FETCH_NEXT.

  • SQLDrivers

    (DM) The value specified for the argument Direction was not equal to SQL_FETCH_FIRST or SQL_FETCH_NEXT.

HY104Invalid precision or scale value
  • SQLBindParameter

    The value specified for the argument ColumnSize or DecimalDigits was outside the range of values supported by the data source for a column of the SQL data type specified by the ParameterType argument.

HY105Invalid parameter type
HY106Fetch type out of range
  • SQLExtendedFetch

    (DM) The value specified for the argument FetchOrientation was invalid. 

    The argument FetchOrientation was SQL_FETCH_BOOKMARK, and the SQL_ATTR_USE_BOOKMARKS statement attribute was set to SQL_UB_OFF.

    The value of the SQL_CURSOR_TYPE statement option was SQL_CURSOR_FORWARD_ONLY, and the value of argument FetchOrientation was not SQL_FETCH_NEXT.

    The argument FetchOrientation was SQL_FETCH_RESUME.

  • SQLFetchScroll

    (DM) The value specified for the argument FetchOrientation was invalid.

    (DM) The argument FetchOrientation was SQL_FETCH_BOOKMARK, and the SQL_ATTR_USE_BOOKMARKS statement attribute was set to SQL_UB_OFF.

    The value of the SQL_ATTR_CURSOR_TYPE statement attribute was SQL_CURSOR_FORWARD_ONLY, and the value of argument FetchOrientation was not SQL_FETCH_NEXT.

    The value of the SQL_ATTR_CURSOR_SCROLLABLE statement attribute was SQL_NONSCROLLABLE, and the value of argument FetchOrientation was not SQL_FETCH_NEXT.

HY107Row value out of range
  • SQLExtendedFetch

    The value specified with the SQL_CURSOR_TYPE statement option was SQL_CURSOR_KEYSET_DRIVEN, but the value specified with the SQL_KEYSET_SIZE statement attribute was greater than 0 and less than the value specified with the SQL_ROWSET_SIZE statement attribute.

  • SQLFetch, SQLFetchScroll

    The value specified with the SQL_ATTR_CURSOR_TYPE statement attribute was SQL_CURSOR_KEYSET_DRIVEN, but the value specified with the SQL_ATTR_KEYSET_SIZE statement attribute was greater than 0 and less than the value specified with the SQL_ATTR_ROW_ARRAY_SIZE statement attribute.

  • SQLSetPos

    The value specified for the argument RowNumber was greater than the number of rows in the rowset.

HY109Invalid cursor position
  • SQLExecDirect

    *StatementText contained a positioned update or delete statement, and the cursor was positioned (by SQLSetPos or SQLFetchScroll) on a row that had been deleted or could not be fetched.

  • SQLExecute

    The prepared statement was a positioned update or delete statement, and the cursor was positioned (by SQLSetPos or SQLFetchScroll) on a row that had been deleted or could not be fetched.

  • SQLGetData

    The cursor was positioned (by SQLSetPos, SQLFetch, SQLFetchScroll, or SQLBulkOperations ) on a row that had been deleted or could not be fetched.

    The cursor was a forward-only cursor, and the rowset size was greater than one.

  • SQLGetStmtAttr

    The Attribute argument was SQL_ATTR_ROW_NUMBER and the row had been deleted or could not be fetched.

  • SQLNativeSql

    The current row of the cursor had been deleted or had not been fetched. This error may not be returned by a driver having a native DBMS cursor implementation.

  • SQLParamData
  • SQLSetPos

    The cursor associated with the StatementHandle was defined as forward-only, so the cursor could not be positioned within the rowset. See the description for the SQL_ATTR_CURSOR_TYPE attribute in SQLSetStmtAttr.

    The Operation argument was SQL_UPDATE, SQL_DELETE, or SQL_REFRESH, and the row identified by the RowNumber argument had been deleted or had not been fetched.

    (DM) The RowNumber argument was 0, and the Operation argument was SQL_POSITION.

    SQLSetPos was called after SQLBulkOperations was called and before SQLFetchScroll or SQLFetch was called.

HY110Invalid driver completion
  • SQLDriverConnect

    (DM) The value specified for the argument DriverCompletion was not equal to SQL_DRIVER_PROMPT, SQL_DRIVER_COMPLETE, SQL_DRIVER_COMPLETE_REQUIRED, or SQL_DRIVER_NOPROMPT.

    (DM) Connection pooling was enabled, and the value specified for the argument DriverCompletion was not equal to SQL_DRIVER_NOPROMPT.

HY111Invalid bookmark value
  • SQLExtendedFetch

    The argument FetchOrientation was SQL_FETCH_BOOKMARK, and the bookmark specified in the FetchOffset argument was not valid.

  • SQLFetchScroll

    The argument FetchOrientation was SQL_FETCH_BOOKMARK, and the bookmark pointed to by the value in the SQL_ATTR_FETCH_BOOKMARK_PTR statement attribute was not valid or was a null pointer.

HYC00Optional feature not implemented
  • SQLAllocHandle

    The HandleType argument was SQL_HANDLE_DESC and the driver was an ODBC 2.x driver.

  • SQLBindCol, SQLBindParameter

    The driver or data source does not support the conversion specified by the combination of the TargetType argument and the driver-specific SQL data type of the corresponding column.

    The argument ColumnNumber was 0 and the driver does not support bookmarks.

    The driver supports only ODBC 2.x and the argument TargetType was one of the following:
    SQL_C_GUID
    SQL_C_NUMERIC
    SQL_C_SBIGINT
    SQL_C_UBIGINT

    and any of the interval C data types listed in "Data Types " in Appendix D: Data Types.

  • SQLBulkOperations

    The driver or data source does not support the operation requested in the Operation argument.

  • SQLColAttribute

    The value specified for the argument FieldIdentifier was not supported by the driver.

  • SQLColumnPrivileges

    A catalog name was specified, and the driver or data source does not support catalogs.

    A schema name was specified, and the driver or data source does not support schemas.

    A string search pattern was specified for the column name, and the data source does not support search patterns for that argument.

    The combination of the current settings of the SQL_CONCURRENCY and SQL_CURSOR_TYPE statement attributes was not supported by the driver or data source.

    The SQL_ATTR_USE_BOOKMARKS statement attribute was set to SQL_UB_VARIABLE, and the SQL_ATTR_CURSOR_TYPE statement attribute was set to a cursor type for which the driver does not support bookmarks.

  • SQLColumns

    A catalog name was specified, and the driver or data source does not support catalogs.

    A schema name was specified, and the driver or data source does not support schemas.

    A string search pattern was specified for the schema name, table name, or column name, and the data source does not support search patterns for one or more of those arguments.

    The combination of the current settings of the SQL_ATTR_CONCURRENCY and SQL_ATTR_CURSOR_TYPE statement attributes was not supported by the driver or data source.

    The SQL_ATTR_USE_BOOKMARKS statement attribute was set to SQL_UB_VARIABLE, and the SQL_ATTR_CURSOR_TYPE statement attribute was set to a cursor type for which the driver does not support bookmarks.

  • SQLDriverConnect

    The driver does not support the version of ODBC behaviour that the application requested.

  • SQLEndTran

    The driver or data source does not support the ROLLBACK operation.

  • SQLExecDirect, SQLExecute

    The combination of the current settings of the SQL_ATTR_CONCURRENCY and SQL_ATTR_CURSOR_TYPE statement attributes was not supported by the driver or data source.

    The SQL_ATTR_USE_BOOKMARKS statement attribute was set to SQL_UB_VARIABLE, and the SQL_ATTR_CURSOR_TYPE statement attribute was set to a cursor type for which the driver does not support bookmarks.

  • SQLExtendedFetch

    Driver or data source does not support the specified fetch type.

    The driver or data source does not support the conversion specified by the combination of the TargetType in SQLBindCol and the SQL data type of the corresponding column. This error applies only when the SQL data type of the column was mapped to a driver-specific SQL data type.

  • SQLFetch

    The driver or data source does not support the conversion specified by the combination of the TargetType in SQLBindCol and the SQL data type of the corresponding column.

  • SQLFetchScroll

    Driver or data source does not support the specified fetch type.

    The driver or data source does not support the conversion specified by the combination of the TargetType in SQLBindCol and the SQL data type of the corresponding column.

    FetchOrientation was SQL_FETCH_BOOKMARK, FetchOffset was not equal to 0, and the underlying driver is an ODBC 2.x driver.

  • SQLForeignKeys

    A catalog name was specified, and the driver or data source does not support catalogs.

    A schema name was specified, and the driver or data source does not support schemas.

    The combination of the current settings of the SQL_ATTR_CONCURRENCY and SQL_ATTR_CURSOR_TYPE statement attributes was not supported by the driver or data source.

    The SQL_ATTR_USE_BOOKMARKS statement attribute was set to SQL_UB_VARIABLE, and the SQL_ATTR_CURSOR_TYPE statement attribute was set to a cursor type for which the driver does not support bookmarks.

  • SQLGetConnectAttr

    The value specified for the argument Attribute was a valid ODBC connection attribute for the version of ODBC supported by the driver, but was not supported by the driver.

  • SQLGetData

    The driver or data source does not support use of SQLGetData with multiple rows in SQLFetchScroll. This description does not apply to drivers that return the SQL_GD_BLOCK bitmask for the SQL_GETDATA_EXTENSIONS option in SQLGetInfo.

    The driver or data source does not support the conversion specified by the combination of the TargetType argument and the SQL data type of the corresponding column. This error applies only when the SQL data type of the column was mapped to a driver-specific SQL data type.

    The driver supports only ODBC 2.x, and the argument TargetType was one of the following:
    SQL_C_GUID
    SQL_C_NUMERIC
    SQL_C_SBIGINT
    SQL_C_UBIGINT

    and any of the interval C data types listed in "C Data Types" in Appendix D: Data Types.

  • SQLGetEnvAttr
  • SQLGetInfo

    The value specified for the argument InfoType was a driver-specific value that is not supported by the driver.

  • SQLGetStmtAttr

    The value specified for the argument Attribute was a valid ODBC statement attribute for the version of ODBC supported by the driver, but was not supported by the driver.

  • SQLGetTypeInfo

    The combination of the current settings of the SQL_ATTR_CONCURRENCY and SQL_ATTR_CURSOR_TYPE statement attributes was not supported by the driver or data source.

    The SQL_ATTR_USE_BOOKMARKS statement attribute was set to SQL_UB_VARIABLE, and the SQL_ATTR_CURSOR_TYPE statement attribute was set to a cursor type for which the driver does not support bookmarks.

  • SQLParamData
  • SQLPrepare

    The concurrency setting was invalid for the type of cursor defined.

    The SQL_ATTR_USE_BOOKMARKS statement attribute was set to SQL_UB_VARIABLE, and the SQL_ATTR_CURSOR_TYPE statement attribute was set to a cursor type for which the driver does not support bookmarks.

  • SQLPrimaryKeys

    A catalog was specified, and the driver or data source does not support catalogs.

    A schema was specified and the driver or data source does not support schemas.

    The combination of the current settings of the SQL_ATTR_CONCURRENCY and SQL_ATTR_CURSOR_TYPE statement attributes was not supported by the driver or data source.

    The SQL_ATTR_USE_BOOKMARKS statement attribute was set to SQL_UB_VARIABLE, and the SQL_ATTR_CURSOR_TYPE statement attribute was set to a cursor type for which the driver does not support bookmarks.

  • SQLProcedureColumns, SQLProcedures

    A procedure catalog was specified, and the driver or data source does not support catalogs.

    A procedure schema was specified, and the driver or data source does not support schemas.

    A string search pattern was specified for the procedure schema, procedure name, or column name, and the data source does not support search patterns for one or more of those arguments.

    The combination of the current settings of the SQL_ATTR_CONCURRENCY and SQL_ATTR_CURSOR_TYPE statement attributes was not supported by the driver or data source.

    The SQL_ATTR_USE_BOOKMARKS statement attribute was set to SQL_UB_VARIABLE, and the SQL_ATTR_CURSOR_TYPE statement attribute was set to a cursor type for which the driver does not support bookmarks.

  • SQLSetConnectAttr

    The value specified for the argument Attribute was a valid ODBC connection or statement attribute for the version of ODBC supported by the driver but was not supported by the driver.

  • SQLSetEnvAttr

    The value specified for the argument Attribute was a valid ODBC environment attribute for the version of ODBC supported by the driver, but was not supported by the driver.

    (DM) The Attribute argument was SQL_ATTR_OUTPUT_NTS, and ValuePtr was SQL_FALSE.

  • SQLSetPos

    The driver or data source does not support the operation requested in the Operation argument or the LockType argument.

  • SQLSetStmtAttr

    The value specified for the argument Attribute was a valid ODBC statement attribute for the version of ODBC supported by the driver but was not supported by the driver.

    The Attribute argument was SQL_ATTR_ASYNC_ENABLE, and a call to SQLGetInfo with an InfoType of SQL_ASYNC_MODE returns SQL_AM_CONNECTION.

    The Attribute argument was SQL_ATTR_ENABLE_AUTO_IPD, and the value of the connection attribute SQL_ATTR_AUTO_IPD was SQL_FALSE.

  • SQLSpecialColumns, SQLStatistics

    A catalog was specified, and the driver or data source does not support catalogs.

    A schema was specified, and the driver or data source does not support schemas.

    The combination of the current settings of the SQL_ATTR_CONCURRENCY and SQL_ATTR_CURSOR_TYPE statement attributes was not supported by the driver or data source.

    The SQL_ATTR_USE_BOOKMARKS statement attribute was set to SQL_UB_VARIABLE, and the SQL_ATTR_CURSOR_TYPE statement attribute was set to a cursor type for which the driver does not support bookmarks.

  • SQLTablePrivileges, SQLTables

    A catalog was specified, and the driver or data source does not support catalogs.

    A schema was specified, and the driver or data source does not support schemas.

    A string search pattern was specified for the table schema, table name, or column name, and the data source does not support search patterns for one or more of those arguments.

    The combination of the current settings of the SQL_ATTR_CONCURRENCY and SQL_ATTR_CURSOR_TYPE statement attributes was not supported by the driver or data source.

    The SQL_ATTR_USE_BOOKMARKS statement attribute was set to SQL_UB_VARIABLE, and the SQL_ATTR_CURSOR_TYPE statement attribute was set to a cursor type for which the driver does not support bookmarks.

HYT00Timeout expired
HYT01Connection timeout expired

Download ODBC Drivers for Oracle, SQL Server, Firebird, ISAM, InterBase, Sybase, MS Access and more.

SQLSTATE IM

SQLSTATEErrorCan be returned from
IM001Driver does not support this function All ODBC functions except:
IM002Data source name not found and no default driver specified
  • SQLBrowseConnect

    (DM) The data source name specified in the browse request connection string (InConnectionString) was not found in the system information, nor was there a default driver specification.

    (DM) ODBC data source and default driver information could not be found in the system information.

  • SQLConnect

    (DM) The data source name specified in the argument ServerName was not found in the system information, nor was there a default driver specification.

  • SQLDriverConnect

    (DM) The data source name specified in the connection string (InConnectionString) was not found in the system information, and there was no default driver specification.

    (DM) ODBC data source and default driver information could not be found in the system information.

IM003Specified driver could not be loaded
  • SQLBrowseConnect

    (DM) The driver listed in the data source specification in the system information or specified by the DRIVER keyword was not found or could not be loaded for some other reason.

  • SQLConnect

    (DM) The driver listed in the data source specification in system information was not found or could not be connected to for some other reason.

  • SQLDriverConnect

    (DM) The driver listed in the data source specification in the system information or specified by the DRIVER keyword was not found or could not be loaded for some other reason.

IM004Driver's SQLAllocHandle on SQL_HANDLE_ENV failed
IM005Driver's SQLAllocHandle on SQL_HANDLE_DBC failed
IM006Driver's SQLSetConnectAttr failed
IM007No data source or driver specified; dialog prohibited
  • SQLDriverConnect

    No data source name or driver was specified in the connection string, and DriverCompletion was SQL_DRIVER_NOPROMPT.

IM008Dialog failed
  • SQLDriverConnect

    The driver attempted to display its login dialog box and failed.

    WindowHandle was a null pointer, and DriverCompletion was not SQL_DRIVER_NO_PROMPT.

IM009Unable to load translation DLL
  • SQLBrowseConnect, SQLDriverConnect

    The driver was unable to load the translation DLL that was specified for the data source or for the connection.

  • SQLConnect

    The driver was unable to connect to the translation DLL that was specified for the data source.

  • SQLSetConnectAttr

    The driver was unable to load the translation DLL that was specified for the connection. This error can be returned only when Attribute is SQL_ATTR_TRANSLATE_LIB.

IM010Data source name too long
  • SQLBrowseConnect

    (DM) The attribute value for the DSN keyword was longer than SQL_MAX_DSN_LENGTH characters.

  • SQLConnect

    (DM) *ServerName was longer than SQL_MAX_DSN_LENGTH characters.

  • SQLDriverConnect

    (DM) The attribute value for the DSN keyword was longer than SQL_MAX_DSN_LENGTH characters.

IM011Driver name too long
IM012DRIVER keyword syntax error
  • SQLBrowseConnect

    (DM) The keyword-value pair for the DRIVER keyword contained a syntax error.

  • SQLDriverConnect

    (DM) The keyword-value pair for the DRIVER keyword contained a syntax error.

    (DM) The string in *InConnectionString contained a FILEDSN keyword, but the .dsn file did not contain a DRIVER keyword or a DSN keyword.

IM013Trace file error
IM014Invalid name of File DSN
  • SQLDriverConnect

    (DM) The string in *InConnectionString contained a FILEDSN keyword, but the name of the .dsn file was invalid.

IM015Corrupt file data source
  • SQLDriverConnect

    (DM) The string in *InConnectionString contained a FILEDSN keyword, but the .dsn file was unreadable.



© 1993 - 2010 Easysoft Limited. All rights reserved.