ST_PointFromGeoHash
Create a Point geometry from a Geohash. This function decodes a Geohash string into a Point object representing the location's center.
Syntax
ST_PointFromGeoHash(geohash, srid)Description
Examples
SELECT ST_ASTEXT(ST_POINTFROMGEOHASH("s00twy01mtw037m",0));
+-----------------------------------------------------+
| ST_ASTEXT(ST_POINTFROMGEOHASH("s00twy01mtw037m",0)) |
+-----------------------------------------------------+
| POINT(1 1) |
+-----------------------------------------------------+
SELECT ST_ASTEXT(ST_POINTFROMGEOHASH(ST_GEOHASH(180,90,20),0));
+---------------------------------------------------------+
| ST_ASTEXT(ST_POINTFROMGEOHASH(ST_GEOHASH(180,90,20),0)) |
+---------------------------------------------------------+
| POINT(180 90) |
+---------------------------------------------------------+See Also
Last updated
Was this helpful?

