The PROVIDER_TYPES rowset identifies the (base) data types supported by the data provider.
The PROVIDER_TYPES rowset contains the following columns:
Column name | Type indicator | Description |
TYPE_NAME | DBTYPE_WSTR | Provider-specific data type name. |
DATA_TYPE | DBTYPE_UI2 | The indicator of the data type. |
COLUMN_SIZE | DBTYPE_UI4 | The length of a non-numeric column or parameter refers to either the maximum or the defined length for this type by the provider. For character data, this is the maximum or defined length in characters. If the data type is numeric, this is the upper bound on the maximum precision of the data type. For the maximum precision of the data type. |
LITERAL_PREFIX | DBTYPE_WSTR | Character or characters used to prefix a literal of this type in a text command. |
LITERAL_SUFFIX | DBTYPE_WSTR | Character or characters used to suffix a literal of this type in a text command. |
CREATE_PARAMS | DBTYPE_WSTR | The creation parameters are specified by the consumer when creating a column of this data type. For example, the SQL data type DECIMAL needs a precision and a scale. In this case, the creation parameters might be the string “precision, scale.” In the text command to create a DECIMAL column with a precision of 10 and a scale of 2, the value of the TYPE_NAME column might be DECIMAL() and the complete type specification would be DECIMAL(10,2). The creation parameters appear as a comma-separated list of values, in the order they are to be supplied, with no surrounding parentheses. If a creation parameter is length, maximum length, precision, or scale, “length,” “max length,” “precision,” and “scale” should be used, respectively. If the creation parameters are some other value, it is provider-specific what text is used to describe the creation parameter. If the data type required creation parameters, “()” generally appears in the type name. This indicates the position at which to insert the creation parameters. If the type name does not include “()”, the creation parameters are enclosed in parentheses and appended to the end of the data type name. |
IS_NULLABLE | DBTYPE_BOOL | Specifies values as:
|
CASE_SENSITIVE | DBTYPE_BOOL | Specifies values as either of:
|
SEARCHABLE | DBTYPE_UI4 | If the provider supports ICommandText, then this column is an integer indicating the searchability of a data type. Otherwise, this column is NULL. Specifies values as one of:
|
UNSIGNED _ATTRIBUTE | DBTYPE_BOOL | Specifies values as:
|
FIXED_PREC_SCALE | DBTYPE_BOOL | Specifies values as one of:
|
AUTO_UNIQUE_VALUE | DBTYPE_BOOL | Specifies values as one of:
|
LOCAL_TYPE_NAME | DBTYPE_WSTR | Localized version of TYPE_NAME. NULL is returned if a localized name is not supported by the data provider. |
MINIMUM_SCALE | DBTYPE_I2 | If the type indicator is DBTYPE_DECIMAL or DBTYPE_NUMERIC, this is the minimum number of digits allowed to the right of the decimal point. Otherwise, this is NULL. |
MAXIMUM_SCALE | DBTYPE_I2 | If the type indicator is DBTYPE_DECIMAL or DBTYPE_NUMERIC, this is the maximum number of digits allowed to the right of the decimal point. Otherwise, this is NULL. |
GUID | DBTYPE_GUID | The GUID of the type. All types supported by a provider are described in a type library, so each type has a corresponding GUID. |
TYPELIB | DBTYPE_WSTR | The type library containing the description of this type. |
VERSION | DBTYPE_WSTR | The version of the type definition. Providers may wish to indicate version type definitions. Different providers may use different version schemas, such as a timestamp or number (integer or float). NULL if not supported. |
IS_LONG | DBTYPE_BOOL | This value determines the setting of the DBCOLUMNFLAGS_ISLONG flag returned by GetColumnInfo in IColumnsInfo and GetParameterInfo in ICommandWithParameters. Specifies values as one of:
|
BEST_MATCH | DBTYPE_BOOL | Specifies values as one of:
For each set of rows in which the value of the DATA_TYPE column is the same, the BEST_MATCH column is set to VARIANT_TRUE in only one row. |
Default Sort Order: DATA_TYPE.