Data types
- Last Updated: August 23, 2024
- 1 minute read
- DataDirect Connectors
- JDBC
- Apache Hive 6.0
- Documentation
The following table shows how the Apache Hive data types are mapped to the standard JDBC data types.
See "getTypeInfo()" for getTypeInfo() results of data types supported by the driver.
| Apache Hive | JDBC |
|---|---|
| Array | LONGVARCHAR |
| Bigint | BIGINT |
| Binary | VARBINARY or LONGVARBINARY1 |
| Boolean | BOOLEAN |
| Char | CHAR |
| Date | DATE |
| Decimal2 | DECIMAL |
| Double | DOUBLE |
| Float | REAL |
| Int | INTEGER |
| Map | LONGVARCHAR |
| Smallint | SMALLINT |
| String3 | VARCHAR or LONGVARCHAR4 |
| Struct | LONGVARCHAR |
| Timestamp | TIMESTAMP |
| Tinyint | TINYINT |
| Union | LONGVARCHAR |
| Varchar | VARCHAR |
1 If the BinaryDescribeType property
is set to
varbinary (the default),
this data type maps to VARBINARY. If set to longvarbinary, this data type maps to
LONGVARBINARY.2 Decimal is supported as a
user-defined, variable precision data type.
3 Maximum of 2 GB
4 If the StringDescribeType property is set to
varchar (the default), this data type maps to
VARCHAR. If set to longvarchar, this data type maps
to LONGVARCHAR.