David Collins ha scritto:
Hello.
The zipped shapefile ('SHAPE-ZIP') output seems to be a very handy option.
This works nicely ..
http://dpi12345:8080/geoserver/wfs?request=getfeature&outputFormat=SHAPE-ZIP&typename=Deposit
But this does not work ...
http://dpi12345:8080/geoserver/wfs?request=getfeature&outputFormat=SHAPE-ZIP&bbox=147.507982,-33.111750,148.466785,-32.786320&typename=Deposit
Is there any get-around (alternate URL?) to output a subset of the feature set?
The filtering and output generation are two completely independent
steps, they are not specific to the shape-zip output.
For example, this one works:
http://geo.openplans.org:8080/geoserver/wfs?request=GetFeature&version=1.0.0&typeName=topp:states&BBOX=-75.102613,40.212597,-72.361859,41.512517
and this one, using SHAPE-ZIP, works as well:
http://geo.openplans.org:8080/geoserver/wfs?request=GetFeature&version=1.0.0&typeName=topp:states&BBOX=-75.102613,40.212597,-72.361859,41.512517&outputFormat=SHAPE-ZIP
I notice you did not specify the version in your requests, you should state version=1.0.0, otherwise wfs 1.1 will
be assumed and you'll run into ttp://jira.codehaus.org/browse/GEOS-2397
(so your first request will generate a shapefile with coordinates in
lat/lon order, I guess most software won't open it properly).
Also, in WFS 1.1 the bbox is assumed to be lat/lon, which would explain
why you don't get anything back with the bbox filter.
See also
http://geoserver.org/display/GEOSDOC/2.+WFS+-+Web+Feature+Service
("the axis order issue")
Cheers
Andrea
Hi,
Just wondering, that if WFS version is not given then the default is the highest, 1.1 nowadays, which flipped the coordinate axis order. What happens if you add &version=1.0 to your request? Or change the order of lat and lon coordinates? But if this happens to be the case then 147 degrees as latitude would not make much sense and perhaps it should lead to some informative message instead of an empty map.
-Jukka Rahkonen-
David Collins wrote:
Hello.
The zipped shapefile ('SHAPE-ZIP') output seems to be a very handy option.
This works nicely ..
http://dpi12345:8080/geoserver/wfs?request=getfeature&outputFormat=SHAPE-ZIP&typename=Deposit
But this does not work ...
http://dpi12345:8080/geoserver/wfs?request=getfeature&outputFormat=SHAPE-ZIP&bbox=147.507982,-33.111750,148.466785,-32.786320&typename=Deposit
Is there any get-around (alternate URL?) to output a subset of the feature
set?
Regards,
David Collins