2

I want to download some information about lots using WFS hosted by http://geoportal.gov.pl/ .

I've tried download data with this link:

http://mapy.geoportal.gov.pl/wss/service/pub/guest/G2_GO_WFS/MapServer/WFSServer?service=WFS&version=1.1.0&REQUEST=GetFeature&typename=Dzialki&srsname=EPSG:2180&BBOX=30,30,30.001,30.001&

Unfortunately returned XML doesn't contain any interesting data...

<wfs:FeatureCollection xsi:schemaLocation='http://mapy.geoportal.gov.pl:80/wss/service/pub/guest/G2_GO_WFS/MapServer/WFSServer http://mapy.geoportal.gov.pl:80/wss/service/pub/guest/G2_GO_WFS/MapServer/WFSServer?request=DescribeFeatureType%26version=1.1.0%26typename=Dzialki http://www.opengis.net/wfs http://schemas.opengis.net/wfs/1.1.0/wfs.xsd' xmlns:G2_GO_WFS='http://mapy.geoportal.gov.pl:80/wss/service/pub/guest/G2_GO_WFS/MapServer/WFSServer' xmlns:gml='http://www.opengis.net/gml' xmlns:wfs='http://www.opengis.net/wfs' xmlns:xlink='http://www.w3.org/1999/xlink' xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance'>
<gml:boundedBy>
<gml:Envelope srsName='EPSG:2180'>
<gml:lowerCorner>133223.25099999999 171678.07000000001</gml:lowerCorner>
<gml:upperCorner>774923.77999999898 861902.51000000001</gml:upperCorner>
</gml:Envelope>
</gml:boundedBy>
</wfs:FeatureCollection>

I've tried variety of coordinates and BBOX values, but I've always got the same XML in response.

How can I get data from geoportal?

  • I made some quick test with no success. I would ask directly from the maintainer of the Polish geoportal how the BBOX should be used with their service. Your request is right if the WFS 1.1.0 standard is read literally (default BBOX is in EPSG:4326 in lon-lat axis order) but many WFS servers use different interpretation.odd just in this place and mo – user30184 Jul 30 '14 at 20:01
2

When requesting data from a WFS the first step should always be to look at the GetCapabilties response of the server. The key part of this is:

<wfs:FeatureType>
<wfs:Name>G2_GO_WFS:Dzialki</wfs:Name>
<wfs:Title>Dzialki</wfs:Title>
<wfs:DefaultSRS>urn:ogc:def:crs:EPSG:6.9:2180</wfs:DefaultSRS>
<wfs:OtherSRS>urn:ogc:def:crs:EPSG:6.9:4326</wfs:OtherSRS>
<wfs:OutputFormats>
<wfs:Format>text/xml; subType=gml/3.1.1/profiles/gmlsf/1.0.0/0</wfs:Format>
</wfs:OutputFormats>
<ows:WGS84BoundingBox>
<ows:LowerCorner>13.897789679110796 48.960407986373134</ows:LowerCorner>
<ows:UpperCorner>24.621400708125563 54.837847849328909</ows:UpperCorner>
</ows:WGS84BoundingBox>
</wfs:FeatureType>
</wfs:FeatureTypeList>

So you can ask for the data with a projection of urn:ogc:def:crs:EPSG:6.9:2180 or urn:ogc:def:crs:EPSG:6.9:4326 - it looks like you are trying to specify your bbox in lat/long so use the 4326 urn and your bbox needs to be inside:

<gml:Envelope srsName="urn:ogc:def:crs:EPSG:6.9:4326">
  <gml:lowerCorner>48.960407986373141 13.897789679110796</gml:lowerCorner>
  <gml:upperCorner>54.837847849328917 24.621400708125563</gml:upperCorner>
</gml:Envelope>
  • Thank you, mapy.geoportal.gov.pl/wss/service/pub/guest/G2_GO_WFS/MapServer/… works wery well. – shlAP Jul 31 '14 at 8:53
  • @iant Ok, so the server seems to work as it should according to the standard and it is using EPSG:4326 in lon-lat axis order as the default BBOX. I am curious to know which server it is. At least not Geoserver, but it may be deegree or ArcGIS server. – user30184 Jul 31 '14 at 13:13
  • 1
    It's hard to tell what sort of server it is (and the joy of standards is that it doesn't/shouldn't matter) – Ian Turton Jul 31 '14 at 15:05

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.