Skip to main content
Return the Well-Known Text string representation of a geometry. It will support M coordinate if present since v1.5.0.

Signatures

ST_AsText (A: Geometry)

Parameters

A
Geometry
required
The input geometry.

Return type

A string representation.

Examples

SELECT ST_AsText(ST_SetSRID(ST_Point(1.0,1.0), 3021))
POINT (1 1)
SELECT ST_AsText(ST_MakePointM(1.0, 1.0, 1.0))
POINT M(1 1 1)
SELECT ST_AsText(ST_MakePoint(1.0, 1.0, 1.0, 1.0))
POINT ZM(1 1 1 1)