ST_PointFromText
Signature
GEOMETRY ST_PointFromText(VARCHAR wkt);
GEOMETRY ST_PointFromText(VARCHAR wkt, INT srid);
Description
Converts the Well Known Text wkt into a Geometry, optionally with spatial reference id srid.
Verifies that wkt does in fact specify a POINT.
Note: If wkt specifies a Geometry with z-coordinates, they will be
conserved in reality but suppressed when visualizing the Geometry as WKT.
Note
Implements the OpenGIS Simple Features Implementation Specification for SQL version 1.2.1
Examples
SELECT ST_PointFromText('POINT(25 89)');
-- Answer: POINT(25 89)
SELECT ST_PointFromText('POINT(44 31)', 101);
-- Answer: POINT(44 31)
SELECT ST_PointFromText('MULTIPOINT((2 3), (4 5))', 2154);
-- Answer: The provided WKT Geometry is not a POINT