title: is or supported for comparison of values using text()
body: <p>input xml</p>
  <pre><code>&lt;?xml version='1.0' encoding='UTF-8'?&gt;
  &lt;Report&gt;
      &lt;Employee State=&quot;A&quot;&gt;
          &lt;Information&gt;
              &lt;Data Name=&quot;Rank&quot;&gt;SM1&lt;/Data&gt;
              &lt;Data Name=&quot;City&quot;&gt;CA&lt;/Data&gt;
          &lt;/Information&gt;
      &lt;/Employee&gt;
      &lt;Employee State=&quot;B&quot;&gt;
          &lt;Information&gt;
              &lt;Data Name=&quot;Rank&quot;&gt;SM2&lt;/Data&gt;
              &lt;Data Name=&quot;City&quot;&gt;CA&lt;/Data&gt;
          &lt;/Information&gt;
      &lt;/Employee&gt;
      &lt;Employee State=&quot;A&quot;&gt;
          &lt;Information&gt;
              &lt;Data Name=&quot;Rank&quot;&gt;SM3&lt;/Data&gt;
              &lt;Data Name=&quot;City&quot;&gt;CB&lt;/Data&gt;
          &lt;/Information&gt;
      &lt;/Employee&gt;
      &lt;Employee State=&quot;D&quot;/&gt;
      &lt;Information&gt;
          &lt;Data Name=&quot;Rank&quot;&gt;SM1&lt;/Data&gt;
      &lt;/Information&gt;
  &lt;/Report&gt;
  </code></pre>
  <p>I want to get all &quot;Employee&quot; nodes which are previous to Employee node having &quot;State&quot; attribute value as &quot;D&quot; and whose &quot;Data&quot; element value for which &quot;Name&quot; attributes value is &quot;Rank&quot;, is either SM1 or SM2</p>
  <p>That means for above input I want output like:</p>
  <pre><code>&lt;Employee State=&quot;A&quot;&gt;
          &lt;Information&gt;
              &lt;Data Name=&quot;Rank&quot;&gt;SM1&lt;/Data&gt;
              &lt;Data Name=&quot;City&quot;&gt;CA&lt;/Data&gt;
          &lt;/Information&gt;
      &lt;/Employee&gt;
      &lt;Employee State=&quot;B&quot;&gt;
          &lt;Information&gt;
              &lt;Data Name=&quot;Rank&quot;&gt;SM2&lt;/Data&gt;
              &lt;Data Name=&quot;City&quot;&gt;CA&lt;/Data&gt;
          &lt;/Information&gt;
      &lt;/Employee&gt;
  </code></pre>
  <p>I am using path expression as</p>
  <pre><code>/Report/Employee[@State='D']/preceding-sibling::Employee/Information[Data[@Name='Rank']/text()='SM1' or text()='SM2']
  </code></pre>
  <p>I also tried to use</p>
  <pre><code>/Report/Employee[@State='D']/preceding-sibling::Employee/Information[Data[@Name='Rank']/text()='SM1' or 'SM2']
  </code></pre>
  <p>I got <a href="https://stackoverflow.com/questions/46503195/xpath-one-of-multiple-attribute-values-with-condition">related question</a></p>
  <p>but it looks like that syntax is valid for attribute value and not the element values, that syntax did not work either.</p>