[mapserver-dev] Unsupported Filter

Farwell, Michael D - Exelis michael.farwell at exelisinc.com
Thu Oct 30 10:55:03 PDT 2014


Rahkonen,

Thanks for an actual working query.

Turns out it was the style of the coordinates.

<gml:coord><gml:X>-59.0</gml:X><gml:Y>-35.0</gml:Y></gml:coord><gml:coord><gml:X>-58.0</gml:X><gml:Y>-34.0</gml:Y></gml:coord>
Vs.
<gml:coordinates cs="," decimal="." ts=" ">-59,-35 -58,-34</gml:coordinates>

Unfortunately, GeoTools formulates the request as X,Y.  There may be a way to override this behavior.

Thanks for your help.

Mike


From: Rahkonen Jukka (Tike) [mailto:jukka.rahkonen at mmmtike.fi]
Sent: Thursday, October 30, 2014 12:20 PM
To: Farwell, Michael D - Exelis; 'Lime, Steve D (MNIT)'; 'mapserver-dev at lists.osgeo.org'
Subject: Re: Unsupported Filter

Hi,

I did not study why it does not work but here is a complete GetFeature POST with BBOX filter that works. Compare with yours and report what makes the difference.

POST http://demo.mapserver.org/cgi-bin/wfs HTTP/1.1
Content-Type: text/xml
User-Agent: Jakarta Commons-HttpClient/3.0-beta1
Host: demo.mapserver.org
Proxy-Connection: Keep-Alive
Content-Length: 835

<wfs:GetFeature service="WFS" version="1.0.0" xmlns:wfs="http://www.opengis.net/wfs" xmlns:ogc="http://www.opengis.net/ogc" xmlns:gml="http://www.opengis.net/gml" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.opengis.net/wfs http://schemas.opengis.net/wfs/1.0.0/WFS-basic.xsd<http://www.opengis.net/wfs%20http:/schemas.opengis.net/wfs/1.0.0/WFS-basic.xsd>" maxFeatures="1000" outputFormat="GML2"><wfs:Query typeName="cities"><ogc:PropertyName>NAME</ogc:PropertyName><ogc:PropertyName>POPULATION</ogc:PropertyName><ogc:PropertyName>msGeometry</ogc:PropertyName><ogc:Filter><ogc:BBOX><ogc:PropertyName>msGeometry</ogc:PropertyName><gml:Box xmlns:gml="http://www.opengis.net/gml"><gml:coordinates cs="," decimal="." ts=" ">-56.020765027322405,-4.650424681845783 -36.836187006678806,25.4390713715847</gml:coordinates></gml:Box></ogc:BBOX></ogc:Filter></wfs:Query></wfs:GetFeature>


-Jukka Rahkonen-


Lähettäjä: mapserver-dev-bounces at lists.osgeo.org<mailto:mapserver-dev-bounces at lists.osgeo.org> [mailto:mapserver-dev-bounces at lists.osgeo.org] Puolesta Farwell, Michael D - Exelis
Lähetetty: 30. lokakuuta 2014 17:42
Vastaanottaja: Lime, Steve D (MNIT); mapserver-dev at lists.osgeo.org<mailto:mapserver-dev at lists.osgeo.org>
Aihe: Re: [mapserver-dev] Unsupported Filter

Steve,

Thanks for the reply.

I'm having the same issue with an internal 6.x mapserver, so I tried the demo server.  Are you aware of other publicly available mapservers that could be used for minimal testing.

Mike

From: Lime, Steve D (MNIT) [mailto:Steve.Lime at state.mn.us]
Sent: Thursday, October 30, 2014 11:38 AM
To: Farwell, Michael D - Exelis; mapserver-dev at lists.osgeo.org<mailto:mapserver-dev at lists.osgeo.org>
Subject: RE: Unsupported Filter

That's a 5.6.5 server. I wonder if newer versions have the same limitation.

From: mapserver-dev-bounces at lists.osgeo.org<mailto:mapserver-dev-bounces at lists.osgeo.org> [mailto:mapserver-dev-bounces at lists.osgeo.org] On Behalf Of Farwell, Michael D - Exelis
Sent: Thursday, October 30, 2014 10:23 AM
To: mapserver-dev at lists.osgeo.org<mailto:mapserver-dev at lists.osgeo.org>
Subject: [mapserver-dev] Unsupported Filter

Mapserver dev,

Does anyone know why the UMN demo map server does not support the following WFS 1.0.0 post request?:

curl -X POST 'http://demo.mapserver.org/cgi-bin/wfs?REQUEST=GetFeature&VERSION=1.0.0&SERVICE=WFS' -d @/tmp/post.xml -H 'Content-Type: application/xml' -k

Where /tmp/post.xml contains:

<?xml version="1.0" encoding="UTF-8"?><wfs:GetFeature xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:ms="http://mapserver.gis.umn.edu/mapserver" xmlns:ogc="http://www.opengis.net/ogc" xmlns:wfs="http://www.opengis.net/wfs" xmlns:gml="http://www.opengis.net/gml" handle="GeoTools 13-SNAPSHOT(f758d2e99d6008f6a27438946de5ef914960f605) WFS 1.0.0 DataStore @localhost.localdomain#1" maxFeatures="10" outputFormat="GML2" service="WFS" version="1.0.0">
<wfs:Query typeName="ms:cities">
  <ogc:PropertyName>POPULATION</ogc:PropertyName>
  <ogc:Filter>
   <ogc:BBOX>
    <ogc:PropertyName>msGeometry</ogc:PropertyName>
    <gml:Box srsName="urn:x-ogc:def:crs:EPSG:4326">
     <gml:coord>
      <gml:X>-59.0</gml:X>
      <gml:Y>-35.0</gml:Y>
     </gml:coord>
     <gml:coord>
      <gml:X>-58.0</gml:X>
      <gml:Y>-34.0</gml:Y>
     </gml:coord>
    </gml:Box>
   </ogc:BBOX>
  </ogc:Filter>
</wfs:Query>
</wfs:GetFeature>

I'm getting the following message:

WFSGetFeature(): WFS server error. Invalid or Unsupported FILTER in GetFeature

Thanks,

Mike

________________________________

This e-mail and any files transmitted with it may be proprietary and are intended solely for the use of the individual or entity to whom they are addressed. If you have received this e-mail in error please notify the sender. Please note that any views or opinions presented in this e-mail are solely those of the author and do not necessarily represent those of Exelis Inc. The recipient should check this e-mail and any attachments for the presence of viruses. Exelis Inc. accepts no liability for any damage caused by any virus transmitted by this e-mail.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/mapserver-dev/attachments/20141030/e3e47af8/attachment-0001.html>


More information about the mapserver-dev mailing list