[postgis-users] Question about Crosses(geometry, geometry)
Matt Doughty
matt.doughty at geograma.com
Fri Jun 8 03:00:14 PDT 2007
Hi List,
I've a question about the CROSSES (geometry, geometry) function. I'd
like to use it to select lines from a table that do not cross, or
intersect, some polygons in a separate table.
The following script lets me select the lines that cross the polygons:
SELECT
lines.*
FROM
lines,
polygons
WHERE
CROSSES(lines.the_geom, polygons.the_geom)
Now I'd like to place a 'NOT' before the function CROSSES (-> NOT
CROSSES(lines.the_geom, polygons.the_geom), rather naively it seems, as
doing that returns me a table with the same geometry as the original
layer, but with 30 times more rows (an increase of 400 to 12,000
records). In other words, it hasn't 'selected' and lines out of the
layer, merely repeated the table geometry 30 times.
Can anybody explain where I'm going wrong?
Many thanks in advance,
Matt
Matt Doughty
GEOGRAMA S.L.
Tel.: +34 945 13 13 72 652 77 14 15
Fax: +34 945 23 03 40
www.geograma.com <http://www.geograma.com/>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/postgis-users/attachments/20070608/6aa2c921/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: image001.jpg
Type: image/jpeg
Size: 3743 bytes
Desc: image001.jpg
URL: <http://lists.osgeo.org/pipermail/postgis-users/attachments/20070608/6aa2c921/attachment.jpg>
More information about the postgis-users
mailing list