SRID conflict, PostgreSQL 8.3 - Mailing list pgsql-general

From csmith
Subject SRID conflict, PostgreSQL 8.3
Date
Msg-id 49C3CA57.3040906@insequenceinc.com
Whole thread Raw
Responses Re: SRID conflict, PostgreSQL 8.3  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-general
Hello,

I serve a Geospatial IS project that for some years has used PostgreSQL
and PostGIS.  A strategy/scheme that has worked for all previous
versions has failed with a recent upgrade to 8.3 (e.g. 8.3.6-1).

Relation "catalog" is a large geospatially-enabled aggregation of data
with a variety of SRID's imbedded within "the_geom" attribute values.
Querying a view into the "catalog" which describes a subset of it's
tuples with identical SRID's (the uniqueness of the SRID associated with
this view's data is easily demonstrable with an ad-hoc query) has always
worked smoothly.  With the 8.3 engine, an error is introduced:

SELECT "whatever"
FROM "a view into 'catalog'"
WHERE ((TRUE AND TRUE) AND "the_geom" && GeometryFromText('POLYGON
((-83.28 26.07,
                                   -83.28 28.26,
                                   -81.59 28.26,
                                   -81.59 26.07,
                                   -83.28 26.07))', -1))

results in this error:

"Operation on two geometries with different SRIDs"

The result of the GeometryFromText routine has, of course, but one SRID,
thus the SRID from "the_geom" must be the culprit.  It's as if the
query is considering tuples in "catalog" outside of the view's domain.
(note: I can offer further evidence of this behavior- removing all tuples
from "catalog" other than those returned by a query against the view
eliminates the conflict/error).

Can someone comment on this mystery/phenomenon vis-a-vis PostgreSQL
version 8.3 (PostGIS 1.3.5)?

Many thanks,
Christopher Smith

pgsql-general by date:

Previous
From: Greg Smith
Date:
Subject: Re: Is there a meaningful benchmark?
Next
From: Greg Smith
Date:
Subject: Re: Is there a meaningful benchmark?