12.07.2015 Views

PostGIS 1.5.8 Manual - Fedora Project Packages GIT repositories

PostGIS 1.5.8 Manual - Fedora Project Packages GIT repositories

PostGIS 1.5.8 Manual - Fedora Project Packages GIT repositories

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

<strong>PostGIS</strong> <strong>1.5.8</strong> <strong>Manual</strong>144 / 310NoteThe WKT spec does not include the SRID. To get the OGC WKT format use ST_AsTextWKT format does not maintain precision so to prevent floating truncation, use ST_AsBinary or ST_AsEWKB format fortransport.NoteST_AsEWKT is the reverse of ST_GeomFromEWKT. Use ST_GeomFromEWKT to convert to a postgis geometry fromST_AsEWKT representation.This function supports 3d and will not drop the z-index.This method supports Circular Strings and CurvesExamplesSELECT ST_AsEWKT(’0103000020E61000000100000005000000000000000000000000000000000000000000000000000000000000000000F03F000000000000F03F000000000000F03F000000000000F03F000000000000000000000000000000000000000000000000’::geometry);st_asewkt--------------------------------SRID=4326;POLYGON((0 0,0 1,1 1,1 0,0 0))(1 row)SELECT ST_AsEWKT(’0108000080030000000000000060 ←↪E30A4100000000785C0241000000000000F03F0000000018E20A4100000000485F024100000000000000400000000018E20A4100000000305C02410000000000000840’)--st_asewkt---CIRCULARSTRING(220268 150415 1,220227 150505 2,220227 150406 3)See AlsoST_AsBinaryST_AsEWKBST_AsText, ST_GeomFromEWKT7.6.4 ST_AsGeoJSONST_AsGeoJSON — Return the geometry as a GeoJSON element.Synopsistext ST_AsGeoJSON(geometry g1);text ST_AsGeoJSON(geography g1);text ST_AsGeoJSON(geometry g1, integer max_decimal_digits);

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!