Data type conversions supported by CLI.
See the tables of data type attributes (precision, scale, length, and display) for more information about the data type formats.
SQL |
S |
S |
S |
S |
S |
S |
S |
S |
S |
S |
S |
S |
S |
S |
S |
S |
S |
S |
S |
S |
S |
S |
S |
S |
S |
S |
S |
S |
S |
S |
S |
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
SQL_CHAR |
D |
X |
|
X |
X |
X |
X |
X |
X |
X |
X |
X |
X |
X |
X |
X |
X |
X |
|
X |
X |
X |
X |
X |
|
X |
|
|
|
|
|
SQL_WCHAR4 |
D |
X |
|
X |
X |
X |
X |
X |
X |
X |
X |
X |
X |
X |
X |
X |
X |
X |
|
X |
X |
X |
X |
X |
|
X |
|
|
|
|
|
SQL_ |
D |
X |
|
X |
X |
X |
X |
X |
X |
X |
X |
X |
X |
X |
X |
X |
X |
X |
|
X |
X |
X |
X |
X |
|
X |
|
|
|
|
|
SQL_ |
D |
X |
|
X |
X |
X |
X |
X |
X |
X |
X |
X |
X |
X |
X |
X |
X |
X |
|
X |
X |
X |
X |
X |
|
X |
|
|
|
|
|
SQL_ |
D |
X |
|
X |
X |
X |
X |
X |
X |
X |
X |
X |
X |
X |
X |
X |
X |
X |
|
X |
X |
X |
X |
X |
|
X |
|
|
|
|
|
SQL_ |
X |
X |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
D |
|
|
|
|
|
SQL_ |
X |
X |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
D |
|
|
|
|
|
SQL_ |
X |
X |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
D |
|
|
|
|
|
SQL_ |
X |
X |
D |
|
|
|
|
X |
|
X |
X |
|
X |
X |
X |
X |
X |
|
|
|
|
|
|
|
|
X |
|
|
|
|
|
SQL_ |
X |
X |
D |
|
|
|
|
X |
|
X |
X |
|
X |
X |
X |
X |
X |
|
|
|
|
|
|
|
|
X |
|
|
|
|
|
SQL_ |
X |
X |
D |
|
|
|
|
X |
|
X |
X |
|
X |
X |
X |
X |
X |
|
|
|
|
|
|
|
|
X |
|
|
|
|
|
SQL_CLOB |
D |
X |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
X |
X |
|
|
|
|
SQL_BLOB |
X |
X |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
D |
|
X |
|
|
|
SQL_DBCLOB |
X |
X |
D |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
X |
|
|
X |
|
|
SQL_ |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
D |
|
|
|
|
SQL_ |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
D |
|
|
|
SQL_ |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
D |
|
|
SQL_NUMERIC |
D |
X |
X5 |
X |
X |
X |
X |
X |
X |
X |
X |
X |
X |
X |
X |
X |
X |
X |
X |
X |
X |
|
|
|
|
X |
|
|
|
|
|
SQL_DECIMAL |
D |
X |
X5 |
X |
X |
X |
X |
X |
X |
X |
X |
X |
X |
X |
X |
X |
X |
X |
X |
X |
X |
|
|
|
|
X |
|
|
|
|
|
SQL_DECFLOAT |
D |
X |
X5 |
X |
X |
X |
X |
X |
X |
X |
X |
X |
X |
X |
X |
X |
X |
X |
X |
X |
|
||||||||||
SQL_INTEGER |
X |
X |
X5 |
X |
X |
X |
X |
X |
X |
X |
D3 |
D3 |
X |
X |
X |
X |
X |
X |
|
X |
X |
|
|
|
|
X |
|
|
|
|
|
SQL_ |
X |
X |
X5 |
X |
X |
X |
X |
D2 |
D2 |
X |
X |
X |
X |
X |
X |
X |
X |
X |
|
X |
X |
|
|
|
|
X |
|
|
|
|
|
SQL_FLOAT |
X |
X |
X5 |
X |
X |
X |
X |
X |
X |
X |
X |
X |
X |
X |
X |
X |
D |
X |
|
X |
X |
|
|
|
|
X |
|
|
|
|
|
SQL_DOUBLE |
X |
X |
X5 |
X |
X |
X |
X |
X |
X |
X |
X |
X |
X |
X |
X |
X |
D |
X |
|
X |
X |
|
|
|
|
X |
|
|
|
|
|
SQL_REAL |
X |
X |
X5 |
X |
X |
X |
X |
X |
X |
X |
X |
X |
X |
X |
X |
D |
X |
X |
|
X |
X |
|
|
|
|
X |
|
|
|
|
|
SQL_BIGINT |
X |
X |
X5 |
X |
X |
X |
X |
X |
X |
X |
X |
X |
X |
D |
X |
X |
X |
X |
|
X |
X |
|
|
|
|
X |
|
|
|
|
|
SQL_TINYINT |
X |
X |
|
X |
D1 |
D1 |
X |
X |
X |
X |
X |
X |
X |
X |
X |
X |
X |
X |
|
X |
X |
|
|
|
|
X |
|
|
|
|
|
SQL_BIT |
X |
X |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
D |
|
|
|
|
|
SQL_ |
X |
X |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
D |
|
X |
|
|
|
|
|
|
|
SQL_ |
X |
X |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
D |
X |
|
|
|
|
|
|
|
SQL_ |
X |
X |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
X |
X |
D |
|
|
|
|
|
|
|
SQL_XML |
X |
X |
D |
X |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
D |
|
|
|
|
SQL_CURSORHANDLE |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
D6 |
In Version 9.7 Fix Pack 1 and later fix packs, the SQL_C_BINARYXML C data type is available for use with the binary XML data in DB2 for z/OS®. Starting in V9.7 Fix Pack 5, SQL_C_BINARYXML C data type can be used with binary XML data in DB2 for Linux, UNIX, and Windows. The DB2 server must also be at a level that supports the binary XML data type. The SQL_XML data type is not supported for use with an Informix® data server.