h3_h3tostring
function
Applies to: Databricks SQL Databricks Runtime 11.3 LTS and above
Converts the input H3 cell ID to its equivalent hexadecimal string representation.
Returns
A value of type STRING. The returned result is the big-endian hexadecimal representation of the input BIGINT with any leading zeros stripped.
The function returns NULL if the input is NULL.
The function converts the BIGINT to its corresponding hexadecimal string.
The function does partial validation regarding whether the input argument is a valid H3 cell ID. A necessary, but not sufficient condition for a valid H3 ID is that its value is between 0x08001fffffffffff
and 0x08ff3b6db6db6db6
.
The behavior of the function is undefined if the input cell ID is not a valid cell ID.
Error conditions
If the value of
h3CellIdExpr
of is smaller than0x08001fffffffffff
or larger than0x08ff3b6db6db6db6
, the function returns H3_INVALID_CELL_ID.