• Industries
  • Products
  • Buy
  • Services & Support
  • Communities
  • Discussion Groups

    Autodesk MapGuide Enterprise

    Reply
    Contributor
    Posts: 11
    Registered: ‎11-27-2012
    Accepted Solution

    Need example of a GetFeature request...

    847 Views, 4 Replies
    11-27-2012 11:43 AM

    I've already posted to gis.stackexchange but did not get a response.  I have minimal Autodesk experience and I think I simple need a working example of a WFS request like the one below:

     

    <Filter xmlns="http://www.opengis.net/ogc">
          <Intersects>
            <PropertyName>Geometry</PropertyName>
            <Polygon srsName="EPSG:26910" xmlns="http://www.opengis.net/gml">
              <exterior>
                <LinearRing>
                  <posList>

    I am getting FBO errors:

     

    Error: An exception occurred in FDO component.
            String does not represent a valid filter. 
     StackTrace:
      - MgFeatureServiceHandler.ProcessOperation() line 83 file d:\build\ims2013\build_52.8\ent\os\server\src\services\feature\FeatureServiceHandler.cpp
    Please use plain text.
    Mentor
    Posts: 238
    Registered: ‎10-06-2008

    Re: Need example of a GetFeature request...

    11-27-2012 05:46 PM in reply to: ca0v

    Perhaps all your XML elements need to be fully qualified with the necesary ogc: gml: and wfs: prefixes?

     

    - Jackie

    Please use plain text.
    Contributor
    Posts: 11
    Registered: ‎11-27-2012

    Re: Need example of a GetFeature request...

    11-28-2012 08:05 AM in reply to: jackie.ng

    By explicitly providing a prefix it worked.  So it is not enough to provide a namespace declaration on the element.

     

    <GetFeature xmlns:wfs="http://www.opengis.net/wfs" service="WFS"
    version="1.1.0" maxFeatures="500" xmlns="http://www.opengis.net/wfs">
      <wfs:Query typeName="ns63133509:ST_WASTE_CONTAINER" SRSNAME="EPSG:26910">
        <ogc:Filter xmlns="http://www.opengis.net/ogc">
          <ogc:Intersects>
            <ogc:PropertyName>Geometry</ogc:PropertyName>
            <gml:Polygon srsName="EPSG:26910" xmlns="http://www.opengis.net/gml">
              <gml:exterior>
                <gml:LinearRing>...</gml:posList>
                </gml:LinearRing>
              </gml:exterior>
            </gml:Polygon>
          </ogc:Intersects>
        </ogc:Filter>
      </wfs:Query>
    </GetFeature>

     

    I also confirmed that the namespace declaration is not necessary in this case:

     

    <GetFeature xmlns:wfs="http://www.opengis.net/wfs" service="WFS"
    version="1.1.0" maxFeatures="500" xmlns="http://www.opengis.net/wfs">
      <wfs:Query typeName="ns63133509:ST_WASTE_CONTAINER" SRSNAME="EPSG:26910">
        <ogc:Filter>
          <ogc:Intersects>
            <ogc:PropertyName>Geometry</ogc:PropertyName>
            <gml:Polygon srsName="EPSG:26910">
              <gml:exterior>
                <gml:LinearRing>
                  <gml:posList>...</gml:posList>
                </gml:LinearRing>
              </gml:exterior>
            </gml:Polygon>
          </ogc:Intersects>
        </ogc:Filter>
      </wfs:Query>
    </GetFeature>

     

    Please use plain text.
    Contributor
    Posts: 11
    Registered: ‎11-27-2012

    Re: Need example of a GetFeature request...

    11-28-2012 09:10 AM in reply to: jackie.ng

    I'm not out of the woods yet...when I provide an explicit namespace declaration it fails.  Is my declaration wrong:

     

    wfs -> default

    ogc -> http://www.opengis.net/ogc

    gml -> http://www.opengis.net/gml

     

     

    <GetFeature xmlns:wfs="http://www.opengis.net/wfs" service="WFS"
    version="1.1.0" maxFeatures="500" xmlns="http://www.opengis.net/wfs">
      <wfs:Query typeName="ns84533269:VanCity" SRSNAME="EPSG:26910">
        <ogc:Filter xmlns:ogc="http://www.opengis.net/ogc">
          <ogc:Intersects>
            <ogc:PropertyName>Geometry</ogc:PropertyName>
            <gml:Polygon srsName="EPSG:26910"
            xmlns:gml="http://www.opengis.net/gml">
              <gml:exterior>
                <gml:LinearRing>
                  <gml:posList>...</gml:posList>
                </gml:LinearRing>
              </gml:exterior>
            </gml:Polygon>
          </ogc:Intersects>
        </ogc:Filter>
      </wfs:Query>
    </GetFeature>

     

    http://www.opengis.net/gml
    Please use plain text.
    Contributor
    Posts: 11
    Registered: ‎11-27-2012

    Re: Need example of a GetFeature request...

    12-14-2012 08:22 AM in reply to: ca0v

    Issue is resolved when a space is added between the <posList> and the first value.

    Please use plain text.