Contents|Index|Previous|Next

Driver-Specific Data Types, Descriptor Types, Information Types, Diagnostic Types, and Attributes

Drivers can allocate driver-specific values for the following:

odbc00090000.gif SQL data type indicators. These are used in ParameterType in SQLBindParameter and DataType in SQLGetTypeInfo and returned by SQLColAttribute, SQLColumns, SQLDescribeCol, SQLGetTypeInfo, SQLDescribeParam, SQLProcedureColumns, and SQLSpecialColumns.

odbc00090000.gif Descriptor fields. These are used in FieldIdentifier in SQLColAttribute, SQLGetDescField, and SQLSetDescField.

odbc00090000.gif Diagnostic fields. These are used in DiagIdentifier in SQLGetDiagField and SQLGetDiagRec.

odbc00090000.gif Information types. These are used in InfoType in SQLGetInfo.

odbc00090000.gif Connection and statement attributes. These are used in Attribute in SQLGetConnectAttr, SQLGetStmtAttr, SQLSetConnectAttr, and SQLSetStmtAttr.

For each of these items, there are two sets of values: values reserved for use by ODBC, and values reserved for use by drivers. Before implementing driver-specific values, a driver writer must request a value for each driver-specific type, field, or attribute from X/Open. Driver-specific data types, descriptor fields, diagnostic fields, information types, statement attributes, and connection attributes must be described in the driver documentation.

When any of these values is passed to an ODBC function, the driver must check whether the value is valid. Note that drivers return SQLSTATE HYC00 (Optional feature not implemented) for driver-specific values that apply to other drivers.