title: xslt get parent element by another element value
body: <p>Im trying to get the parent node based of child element value </p>
  
  <p>I want to do  something like that  <strong>get TransactionDetail element  where SequenceNumber = 2</strong></p>
  
  <p>I tried to do it like that  but im missing something... </p>
  
  <pre><code> ancestor:://*[local-name()='SequenceNumber'][text()=2]
  
   //TransactionDetail[//SequenceNumber = 2]
  </code></pre>
  
  <p>this is the xml </p>
  
  <pre><code>&lt;Root&gt;
  &lt;biztalk_1&gt;
  
      &lt;body&gt;
          &lt;ActiveStore_SalesTransaction_1.70&gt;
  
              &lt;TransactionDetail&gt;
                  &lt;SequenceNumber&gt;2&lt;/SequenceNumber&gt;
  
                  &lt;TransactionDetailGroup&gt;
                      &lt;Item&gt;
                          &lt;ItemID&gt;22&lt;/ItemID&gt;
  
                          &lt;NonMerchandiseFlag&gt;1&lt;/NonMerchandiseFlag&gt;
                      &lt;/Item&gt;
                  &lt;/TransactionDetailGroup&gt;
              &lt;/TransactionDetail&gt;
  
  
  
  
          &lt;/ActiveStore_SalesTransaction_1.70&gt;
      &lt;/body&gt;
  &lt;/biztalk_1&gt;
  </code></pre>
  
  <p></p>