Categories:

Geospatial functions

H3_STRING_TO_INT¶

Converts an H3 cell ID in hexadecimal format to an INTEGER value.

See also:

H3_INT_TO_STRING

Syntax¶

H3_STRING_TO_INT( <cell_id> )
Copy

Arguments¶

cell_id

A VARCHAR that represents the cell ID (index) in hexadecimal format.

Returns¶

Returns an INTEGER value that represents the H3 cell ID.

Examples¶

The following example converts an H3 cell ID from hexadecimal format to an INTEGER value.

SELECT H3_STRING_TO_INT('89283087033FFFF');
Copy
+------------------------------------------------+
|            H3_STRING_TO_INT('89283087033FFFF') |
|------------------------------------------------|
|                             617700171168612351 |
+------------------------------------------------+