...
TIMESTAMP
(Note: Only available starting with Hive 0.8.0)DATE
(Note: Only available starting with Hive 0.12.0)
String Types
Misc Types
...
String literals can be expressed with either single quotes (') or double quotes ("). Hive uses C-style escaping within the strings.
Varchar
Anchor | ||||
---|---|---|---|---|
|
Varchar types are created with a length specifier (between 1 and 65355), which defines the maximum number of characters allowed in the character string. If a string value being converted/assigned to a varchar value exceeds the length specifier, the string is silently truncated. Character length is determined by the number of code points contained by the character string.
Like string, trailing whitespace is significant in varchar and will affect comparison results.
Info | ||
---|---|---|
| ||
Non-generic UDFs cannot directly use varchar type as input arguments or return values. String UDFs can be created instead, and the varchar values will be converted to strings and passed to the UDF. To use varchar arguments directly or to return varchar values, create a GenericUDF. |
Info | ||
---|---|---|
| ||
Varchar datatype was introduced in Hive 0.12.0 (HIVE-4844). |
Timestamps
Anchor | ||||
---|---|---|---|---|
|
...