Skip to content
🎉 Apache Sedona 1.8.1 is now available! Check out the new features and improvements.

ST_AsKML

Introduction: Return the KML string representation of a geometry

Format: ST_AsKML (A: Geometry)

Since: v1.3.0

SQL Example

SELECT ST_AsKML(ST_GeomFromWKT('POLYGON((1 1, 8 1, 8 8, 1 8, 1 1))'))

Output:

1.0,1.0 8.0,1.0 8.0,8.0 1.0,8.0 1.0,1.0