[postgis-users] PostGIS returns no rows for ST_Intersects
mromer at natureserve.ca
Wed Oct 12 20:16:43 PDT 2011
I am new to PostGIS, have only been using it for the last couple of weeks.
I have been using the workshops.opengeo website to learn how to use PostGIS
and am working with the sample NYC database that it came with. I am trying
to test how the ST_Intersect function works so that I can use it on a real
database, but am not getting any rows returned.
Here's what I did:
1. I created a polygon in Google Earth that covers the entire NY state and
then, saved it as a KML.
2. I opened the KML in a text editor used the coordinates to get a geometry
using the ST_GeomFromKML function in PostGIS. The query looks like this:
SELECT ST_GeomFromKML(' <Polygon>
3. When I ran it the resulting geometry was:
4. I copied this into another sql and used the ST_Intersects function, the
SELECT gid, id, "name", oneway, "type", the_geom
where st_intersects (the_geom,
5. I expect to get every single street in the result, however I don't get
any rows returned.
What am I doing wrong?
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the postgis-users