On 29 September 2011 11:20, Sandro Santilli <s...@keybit.net> wrote: > On Thu, Sep 29, 2011 at 11:14:52AM +0200, Szymon Guz wrote: > > Hi, > > I've got a quite strange situation: > > > > this works OK, returns something: > > > > SELECT ... FROM ... WHERE > > st_intersects( > > geometry, > > st_geomfromtext('POINT(3 50)', 4326) > > ); > > > > but this returns nothing: > > > > SELECT ... FROM ... WHERE > > st_intersects( > > geometry, > > st_geomfromtext('POINT(3 50, 3 50 )', 4326) > > ); > > The second should raise an exception due to malformed WKT being used. > Doesn't it ? > > --strk; > > The second raises exception only if there is exactly one point. When there are more points it works OK:
SELECT st_geomfromtext('LINESTRING(3 50)', 4326) ERROR: geometry requires more points HINT: "LINESTRING(3 50)" <-- parse error at position 17 within geometry SELECT st_astext(st_geomfromtext('LINESTRING(3 50, 3 50)', 4326)) 'LINESTRING(3 50,3 50)' - Szymon -- *http://simononsoftware.com/* <http://simononsoftware.com/>
_______________________________________________ postgis-users mailing list postgis-users@postgis.refractions.net http://postgis.refractions.net/mailman/listinfo/postgis-users