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

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

<strong>PostGIS</strong> <strong>1.5.8</strong> <strong>Manual</strong>76 / 310Examples--Create a 3d line string from a 3d multipointSELECT ST_AsEWKT(ST_LineFromMultiPoint(ST_GeomFromEWKT(’MULTIPOINT(1 2 3, 4 5 6, 7 8 9)’))) ←↪;--result--LINESTRING(1 2 3,4 5 6,7 8 9)See AlsoST_AsEWKT, ST_Collect,ST_MakeLine7.3.16 ST_LineFromTextST_LineFromText — Makes a Geometry from WKT representation with the given SRID. If SRID is not given, it defaults to -1.Synopsisgeometry ST_LineFromText(text WKT);geometry ST_LineFromText(text WKT, integer srid);DescriptionMakes a Geometry from WKT with the given SRID. If SRID is not give, it defaults to -1. If WKT passed in is not a LINESTRING,then null is returned.NoteOGC SPEC 3.2.6.2 - option SRID is from the conformance suite.NoteIf you know all your geometries are LINESTRINGS, its more efficient to just use ST_GeomFromText. This just callsST_GeomFromText and adds additional validation that it returns a linestring.This method implements the OpenGIS Simple Features Implementation Specification for SQL 1.1. s3.2.6.2This method implements the SQL/MM specification. SQL-MM 3: 7.2.8ExamplesSELECT ST_LineFromText(’LINESTRING(1 2, 3 4)’) AS aline, ST_LineFromText(’POINT(1 2)’) ASnull_return;aline| null_return------------------------------------------------010200000002000000000000000000F ... | t←↪

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

Saved successfully!

Ooh no, something went wrong!