| Library: ODBC Include: omodbc.xin
 | Returns: Numeric An SQL return code. The following values may be returned: 
 SQL_SUCCESS (the current field values).
SQL_SUCCESS_WITH_INFO (the current field values, but a message was issued).
SQL_ERROR (an error occurred).
SQL_INVALID_HANDLE (the handle is invalid).
SQL_NO_DATA (no data is available).
 | 
Declaration   define external counter function SQLGetDiagField
     (  value counter HandleType,
        read-only SQL_handle_type Handle,
        value counter RecNumber,
        value counter DiagIdentifier,
         read-only SQL_vector_type DiagInfo,
        value counter BufferLength,
        modifiable counter StringLength )
Purpose
Returns the current value of a record field of the diagnostic data structure (associated with a specified handle) that contains error, warning, and status information. 
Input arguments:
- HandleType. The type of handle for which diagnostics are required. The following values are allowed: 
- SQL_HANDLE_ENV
- SQL_HANDLE_DBC
- SQL_HANDLE_STMT
- SQL_HANDLE_DESC
 
- Handle. A handle for the diagnostic data structure, of the type indicated by HandleType. If the handle type is SQL_HANDLE_ENV, the handle can be either a shared or an unshared environment handle.
- RecNumber. Indicates the status record from which the application seeks information. Status records are numbered from one (1). If the DiagIdentifier argument indicates a header field, RecNumber is ignored.
- DiagIdentifier. Indicates the field of the diagnostic whose value is to be returned. The following values are allowed: 
- SQL_DIAG_RETURNCODE
- SQL_DIAG_NUMBER
- SQL_DIAG_ROW_COUNT
- SQL_DIAG_SQLSTATE
- SQL_DIAG_NATIVE
- SQL_DIAG_MESSAGE_TEXT
- SQL_DIAG_DYNAMIC_FUNCTION
- SQL_DIAG_CLASS_ORIGIN
- SQL_DIAG_SUBCLASS_ORIGIN
- SQL_DIAG_CONNECTION_NAME
- SQL_DIAG_SERVER_NAME
- SQL_DIAG_DYNAMIC_FUNCTION_CODE
- SQL_DIAG_ALTER_TABLE
- SQL_DIAG_CREATE_INDEX
- SQL_DIAG_CREATE_TABLE
- SQL_DIAG_CREATE_VIEW
- SQL_DIAG_DELETE_WHERE
- SQL_DIAG_DROP_INDEX
- SQL_DIAG_DROP_TABLE
- SQL_DIAG_DROP_VIEW
- SQL_DIAG_DYNAMIC_DELETE_CURSOR
- SQL_DIAG_DYNAMIC_UPDATE_CURSOR
- SQL_DIAG_GRANT
- SQL_DIAG_INSERT
- SQL_DIAG_REVOKE
- SQL_DIAG_SELECT_CURSOR
- SQL_DIAG_UNKNOWN_STATEMENT
- SQL_DIAG_UPDATE_WHERE
- SQL_DIAG_CURSOR_ROW_COUNT
- SQL_DIAG_ROW_NUMBER
- SQL_DIAG_COLUMN_NUMBER
 
- DiagInfo. The returned diagnostic information. The data type depends on the value of DiagIdentifier.
- BufferLength. The size of the DiagInfo buffer.
Output argument:
- StringLength. The returned size of the DiagInfo buffer.
Generated: April 21, 1999 at 2:01:18 pm
If you have any comments about this section of the documentation, send email to [email protected]
 Copyright © OmniMark Technologies Corporation, 1988-1999.