[mapserver-users] WFS GetFeature with filter for multiple layers

Rahkonen Jukka Jukka.Rahkonen at mmmtike.fi
Wed Jan 23 01:39:37 PST 2013


Hi,

Keep it simple and make two separate GetFeatures, one for each feature type.

-Jukka Rahkonen-

Arjen de Korte wrote:

 
> Hi Steve,
> 
> Yes, for now I (my client) is stuck to this version, so a workaround (or
> accepting that it can't be done) is the only option at the moment. Has this
> been solved in newer versions?
> 
> Kind regards,
> Arjen.
> 
> 
> On Tue, Jan 22, 2013, at 20:15, Lime, Steve D (DNR) wrote:
> > Are you stuck running such an old version?
> >
> > -----Original Message-----
> > From: mapserver-users-bounces at lists.osgeo.org
> > [mailto:mapserver-users-bounces at lists.osgeo.org] On Behalf Of Arjen de
> > Korte
> > Sent: Tuesday, January 22, 2013 10:45 AM
> > To: mapserver-users at lists.osgeo.org
> > Subject: [mapserver-users] WFS GetFeature with filter for multiple
> > layers
> >
> > Hi all,
> >
> > I'm having a problem with Mapserver 5.2.1 and WFS GetFeature requests:
> > when I do a GetFeature request with an OGC filter for more than one
> > layer, I only get results for the first layer. I found a description
> > of the issue here: https://github.com/mapserver/mapserver/issues/3584.
> > It says the issue can be worked around by listing a separate filter
> > for each layer, but I can't work out a way to do this.
> >
> > My original request looks like this:
> >
> > http://myserver.com/cgi-
> bin/mapserv.exe?map=mymapfile.map&Service=WFS&
> >
> Request=GetFeature&TypeName=layer1,layer2&Version=1.0.0&Filter=<ogc:
> Fi
> > lter
> >
> xmlns:ogc="http://www.opengis.net/ogc"><ogc:Intersects><ogc:PropertyN
> a
> > me/><gml:Polygon
> >
> xmlns:gml="http://www.opengis.net/gml"><gml:outerBoundaryIs><gml:Lin
> ea
> > rRing><gml:coordinates decimal="." cs="," ts="
> > ">89760.045356755,436071.75388938
> > 89762.029730683,436071.75388938 89762.029730683,436073.7382633
> > 89760.045356755,436073.7382633
> >
> 89760.045356755,436071.75388938</gml:coordinates></gml:LinearRing></g
> m
> > l:outerBoundaryIs></gml:Polygon></ogc:Intersects></ogc:Filter>
> >
> > ...returning only results for layer1.
> >
> > I've tried repeating the exact same filter like:
> >
> > http://myserver.com/cgi-
> bin/mapserv.exe?map=mymapfile.map&Service=WFS&
> > Request=GetFeature&TypeName=layer1,
> > layer2&Version=1.0.0&Filter=<ogc:Filter
> > xmlns:ogc="http://www.opengis.net/ogc"><ogc:Intersects> ...
> > </ogc:Intersects><ogc:Intersects> ... </ogc:Intersects></ogc:Filter>
> >
> > and
> >
> > http://myserver.com/cgi-
> bin/mapserv.exe?map=mymapfile.map&Service=WFS&
> > Request=GetFeature&TypeName=layer1,
> > layer2&Version=1.0.0&Filter=<ogc:Filter
> > xmlns:ogc="http://www.opengis.net/ogc"><ogc:Intersects> ...
> > </ogc:Intersects></ogc:Filter>,<ogc:Filter><ogc:Intersects> ...
> > </ogc:Intersects></ogc:Filter>
> >
> > ...but the first returns the same: only results for layer1, and the
> > second returns an error.
> >
> > What is the correct way to list multiple filters, or is there another
> > solution to work around this limitation?
> >
> > Thanks!
> >
> > Kind regards,
> > Arjen.
> > _______________________________________________
> > mapserver-users mailing list
> > mapserver-users at lists.osgeo.org
> > http://lists.osgeo.org/mailman/listinfo/mapserver-users
> >
> >
> _______________________________________________
> mapserver-users mailing list
> mapserver-users at lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/mapserver-users


More information about the mapserver-users mailing list