[postgis-users] Error: different SRIDS

Josh Livni postgis at livniconsulting.com
Mon Jul 4 17:04:47 PDT 2005


 


Hi.

I have a large set of parcels I want to query.  They are in NAD83 UTM Zone
10, which I have in the db as EPSG 26910.  

Part of my query will include a knowing a rectangular extent that is a
relatively small section of the overall extent of the parcels.  

If I add a clause as follows:
 where the_geom && 'POLYGON((561648 5288731, 561648 5289731, 571648 5289731,
571648 5288731, 561648 5288731))'; I get ERROR:  Operation on two geometries
with different SRIDs

Interestingly, if I change the polygon to be something like (0 0 ,20 0, 20
20, 0 20, 0 0) I get no error (but no results since that's nowhere near me)

If I select astext(the_geom) from parcels where lastname ilike 'josh%' I get
a bunch of parcels, and it seems clear from their dimensions that some
should align nicely within the above example rectangle.

I tried to force the polygon with a setsrid(polygon, 26910) but I got:
ERROR:  function setsrid("unknown", integer) is not unique

There's probably some simple syntactical thing I'm missing -- any help
appreciated.

   -Josh






More information about the postgis-users mailing list