[Featureserver] problems with OpenLayers WFS

Christopher Schmidt crschmidt at metacarta.com
Thu May 22 11:31:01 EDT 2008


On Thu, May 22, 2008 at 05:23:04PM +0200, G. Allegri wrote:
> I'll do the upgrade to 1.12.
> 
> My featureserver.cfg is:
> [metadata]
> default_service=GeoJSON
> 
> [yyy]
> type=PostGIS
> dsn=host=localhost dbname=iet user=guest password=guest
> layer=yyy
> id=ogc_fid
> geometry=wkb_geometry

Right, no SRS defined in your datasource. Fix that. add srid=3003 to
your DataSource.

> My geometry colums in PostGIS have the SRID setted (EPSG:3003)
> In OL I've setted the srs correctly as you can see from the request
> produced by OL (I've grabbed it with Firebug):
> http://host_url/iet/IETmapfish/client/fs/fs.py/yyy?format=WFS&maxfeatures=600&SERVICE=WFS&VERSION=1.0.0&REQUEST=GetFeature&SRS=EPSG%3A3003&BBOX=1437940.723214286,5056734.944196429,1903269.276785714,5159996.055803571

The SRS sent to the server is ignored.

> If I remove the parameters created by OL the GML is correctly produced...

That's because the problem is when FS tries to SetSRID on the BBOX you
send, and compare it to the geometry, you get an SRS mismatch. Without
the bbox, there's no geometry comparison -- no error.

Regards,
-- 
Christopher Schmidt
MetaCarta



More information about the Featureserver mailing list