[mapserver-users] Trouble with WFS GetFeature: get same feature returned multiple times
Rainer Spittel
rainer at silverstripe.com
Thu Feb 24 16:33:18 PST 2011
Hi,
I didn't had problems with UMN Mapserver for a very long time. I really love the product, and now I really need help.
I set up a WFS Server, accessing a PostGIS point table. I use OpenLayers to visualise the WFS layer, and use the cluster strategy to group close points to a large cluster point.
Now to the problem:
I want to retrieve the feature data from a cluster point. I already have the IDs of the features of the cluster.
Now I send a GetFeature request to the Mapserver to get all attribute information for the features, i.e. ID=231 and ID=273:
http://[...]/cgi-bin/stations?request=getfeature&service=WFS&version=1.0.0&typename=DTIS&OUTPUTFORMAT=gml3&featureid=DTIS.231,DTIS.273
The response of this request contains the feature 231 twice in the response. If I add another ID to the request, I get the feature 231 three times returned:
[...]
<gml:featureMember>
<ms:DTIS gml:id="DTIS.231">
<gml:boundedBy>[...]</gml:boundedBy>
<ms:msGeometry>
<gml:Point srsName="EPSG:4326">
<gml:pos>174.081500 -34.949500</gml:pos>
</gml:Point>
</ms:msGeometry>
<ms:id>231</ms:id>
</ms:DTIS>
</gml:featureMember>
<gml:featureMember>
<ms:DTIS gml:id="DTIS.231">
[...]
</gml:featureMember>
</ms:msFeatureCollection>
As soon as I export the table from PostgreSQL into a shapefile, update the mapfile to use the shapefile and run the same query, I get the correct response. I also tracked the SQL query, which is sent to Postgres, and the query is correct. PostgreSQL returns the correct rows.
I use MapServer V5.4.1, which is not a very newer version, but I am constraint by the Debian packages.
Is this an user error (I am not smart enough)? Or a bug? If so, has this bug been resolved in a later version?
Any help is really appreciated.
Thanks,
Rainer
Rainer Spittel | Head of Development
SilverStripe
http://silverstripe.com
Phone: +64 4 978 7330
Mobile: +64 21 1390370
Skype: fb3rasp
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/mapserver-users/attachments/20110225/577d61a5/attachment.htm>
More information about the MapServer-users
mailing list