[postgis-users] Error: different SRIDS

strk at refractions.net strk at refractions.net
Mon Jul 4 17:09:12 PDT 2005


Use the SRID=#; prefix to your POLYGON text.
--strk;

On Mon, Jul 04, 2005 at 05:04:47PM -0700, Josh Livni wrote:
>  
> 
> 
> 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
> 
> 
> 
> _______________________________________________
> postgis-users mailing list
> postgis-users at postgis.refractions.net
> http://postgis.refractions.net/mailman/listinfo/postgis-users



More information about the postgis-users mailing list