[GIS] SLD filter (PropertyIsEqualTo)

sld

Is an SLD filter like this valid?

<ogc:Filter>
        <ogc:PropertyIsEqualTo>
        <ogc:PropertyName>aaaaaa</ogc:PropertyName>
        <ogc:PropertyName>bbbbb</ogc:PropertyName>
        </ogc:PropertyIsEqualTo>
</ogc:Filter>

or is a Literal always required?

Best Answer

I think Literal is always required with that operator. Morever this snippet code is not valid because seems OR or AND condition: take a look here. An example of your code could be:

<ogc:Or>
   <ogc:PropertyIsEqualTo>
   <ogc:PropertyName>aaaaaa</ogc:PropertyName>
   <ogc:Literal>cccccc</ogc:Literal>
   </ogc:PropertyIsEqualTo>
   <ogc:PropertyIsEqualTo>
   <ogc:PropertyName>bbbbb</ogc:PropertyName>
   <ogc:Literal>ddddddd</ogc:Literal>
   </ogc:PropertyIsEqualTo>
   </ogc:Filter>
 </ogc:Or>