Take the 2-minute tour ×
Geographic Information Systems Stack Exchange is a question and answer site for cartographers, geographers and GIS professionals. It's 100% free, no registration required.

I am new to WFS and am trying to create a filter to get all the features that have their basename = "XYZ". The structure of a single record is as:

<gml:featureMember>
        <core:AdminPlace gml:id="ADMN_21493454">
            <core:featureNames>
                <core:FeatureName>
                    <core:basename>ABC</core:basename>
                    <core:languageCode>ENG</core:languageCode>
                </core:FeatureName>
                <core:FeatureName>
                    <core:basename>DEF</core:basename>
                    <core:languageCode>ENG</core:languageCode>
                </core:FeatureName>
                <core:FeatureName>
                    <core:basename>XYZ</core:basename>
                    <core:languageCode>ENG</core:languageCode>
                </core:FeatureName>
            </core:featureNames>
            <core:adminLevel>4</core:adminLevel>
            <core:dummyAdmin>N</core:dummyAdmin>
         </core:AdminPlace>
    </gml:featureMember>

I am trying to use the XML iput for POST to WFS as:

<?xml version="1.0" encoding="UTF-8"?>
<wfs:GetFeature service="WFS" version="1.0.0"
  xmlns:tns="http://www.abc.com/core"
  xmlns:wfs="http://www.opengis.net/wfs"
  outputFormat="GML3.1">
   <wfs:Query typeName="tns:AdminPlace">
    <ogc:Filter xmlns:ogc="http://www.opengis.net/ogc" xmlns:gml="http://www.opengis.net/gml">
       <ogc:PropertyIsEqualTo>
         <ogc:PropertyName>tns:featureNames/tns:FeatureName/tns:basename</ogc:PropertyName>
        <ogc:Literal>Ellerth</ogc:Literal>
        </ogc:PropertyIsEqualTo>
    </ogc:Filter>
  </wfs:Query>
</wfs:GetFeature>

but I am not able to get the result. The error message thrown is : There was an error processing the event:GetFeatureException: Error while retrieving features: could not resolve property: featureNames.featureName.

Thanks in advance.

share|improve this question
    
Have you tried if the filters are case sensitive? –  underdark Nov 12 '12 at 8:59
    
yes I have tried that, if I change the case of any of the attributes it gives me an error like "Error while trying to validate Filter: Name 'featurenames' is not globaly defined in the namespace" –  Suhail Nov 12 '12 at 9:11
add comment

Know someone who can answer? Share a link to this question via email, Google+, Twitter, or Facebook.

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.