[postgis-users] Error message: "invalid geometry"

Markus Schaber schabi at logix-tt.com
Wed Feb 15 05:48:38 PST 2006


Hi, Stefan,

Stefan Schwarzer wrote:

> *xxx=# insert into gtest (id, name, geom) values (1, 'first geometry',
> GeomFromText('LINESTRING(2,3,4,5,6,5,7,8)', -1));*
> *ERROR:  parse error - invalid geometry*
> *CONTEXT:  SQL function "geomfromtext" statement 1*

Your Linestring representation is syntactically wrong.

Try 'LINESTRING(1 2,3 4,5 6,7 8)' if you want a 2D geometry, and
'LINESTRING(1 2 3,4 5 6,7 8 9)' if you want a 3D geometry.

HTH,
Markus

-- 
Markus Schaber | Logical Tracking&Tracing International AG
Dipl. Inf.     | Software Development GIS

Fight against software patents in EU! www.ffii.org www.nosoftwarepatents.org



More information about the postgis-users mailing list