C to SQL: Binary

The binary HCL OneDB™ ODBC Driver C data type is SQL_C_BINARY.

The following table shows the HCL OneDB ODBC Driver SQL data types to which binary C data can be converted. In the Test column, the SQL data length is the number of bytes needed to store the data on the data source. This length might be different from the column length, as defined in Precision, scale, length, and display size.

The HCL OneDB ODBC Driver SQL data types to which binary C data can be converted.

fSqlType Test SQLSTATE
SQL_BIGINT Length of data = SQL data length. N/A
Length of data � SQL data length. 22003
SQL_BIT Length of data = SQL data length. N/A
Length of data � SQL data length. 22003
SQL_CHAR

SQL_LONGVARCHAR

SQL_VARCHAR

Length of data < Column length. N/A
Length of data > Column length. 01004
SQL_DATE

SQL_TIMESTAMP

Length of data = SQL data length. N/A
Length of data � SQL data length. 22003
SQL_DECIMAL

SQL_DOUBLE

SQL_INTEGER

SQL_REAL

SQL_SMALLINT

Length of data = SQL data length. N/A
Length of data � SQL data length. 22003
SQL_LONGVARBINARY Length of data < Column length. N/A
Length of data > Column length. 01004