Loading

ES|QL TO_GEOHEX function

Embedded
field

Input value. The input can be a single- or multi-valued column or an expression.

Converts an input value to a geohex value. A string will only be successfully converted if it respects the geohex format, as described for the geohex grid aggregation.

field result
geohex geohex
keyword geohex
long geohex
text geohex
ROW string = "841f059ffffffff"
| EVAL geohex = TO_GEOHEX(string)
		
string:keyword geohex:geohex
841f059ffffffff 841f059ffffffff