SQL_DescribeColumn()

Examples


The SQL_DescribeColumn() function retrieves information about the specified column of the current results set for the specified pass-through SQL connection.

Syntax

SQL_DescribeColumn(SQL_connection, column, column_name, datatype, precision, scale)

Parameters

SQL_connection – A long integer specifying the pass-through SQL connection to use.

column – An integer specifying the column in the current results set for which information will be returned. The value 1 indicates the first column.

column_name – A string containing the physical name of the column.

datatype – An integer indicating the datatype associated with the column. The value corresponds to one of the following constants:

[spacer]

DATATYPE_BOOLEAN

DATATYPE_LONG_INTEGER

DATATYPE_VCURRENCY

DATATYPE_STRING

DATATYPE_DATE

DATATYPE_TEXT

DATATYPE_INTEGER

DATATYPE_TIME


Currency and variable currency columns always return the value DATATYPE_VCURRENCY.


precision – If the column contains currency or variable currency data, a long integer indicating the precision (total number of digits available) for each value.

scale – If the column contains currency or variable currency data, an integer indicating the scale (the number of decimal digits) for each value.

Return value

A long integer indicating whether information was retrieved. The value 0 is returned if description information was successfully retrieved. Any other value indicates an error occurred.


Documentation Feedback