Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
Applies to: Databricks Runtime 17.1 and above
Important
This feature is in Public Preview.
Returns the center of the geohash grid box corresponding to the input geohash value as a 2D point geometry.
Syntax
st_pointfromgeohash ( geohash )
Arguments
geohash
: ASTRING
value representing a geohash value.
Returns
A value of type GEOMETRY
, representing the center point of the geohash grid box.
The SRID value of the returned point is 0.
See Wikipedia for more details on geohashes.
The function returns NULL
if the input is NULL
.
Examples
-- Returns the center point of the geohash grid box.
> SELECT st_astext(st_pointfromgeohash('9q8yyh'))
POINT(-122.4261474609375 37.77374267578125)