title: How to parse a complex XML using Xpath
body: <p>I have an XML as below :</p>
  
  <pre><code>&lt;Service xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 
          xmlns="someurl" xsi:schemaLocation="someurl Sample.xsd"&gt;
      &lt;RequestControl&gt;
          &lt;requestID&gt;100129&lt;/requestID&gt;
          &lt;Control&gt;
              &lt;requesterName&gt;Admin&lt;/requesterName&gt;
              &lt;requesterLanguage&gt;100&lt;/requesterLanguage&gt;
          &lt;/Control&gt;
      &lt;/RequestControl&gt;
      &lt;Inquiry&gt;
          &lt;InquiryType&gt;getParty&lt;/InquiryType&gt;
          &lt;InquiryParam&gt;
              &lt;Param name="PartyId"&gt;854850029276139020&lt;/Param&gt;
          &lt;/InquiryParam&gt;
      &lt;/Inquiry&gt;
  &lt;/Service&gt;
  </code></pre>
  
  <p>I want to extract the value "getParty" from  tag using XPath XML Parser. I am using the below as my expression :</p>
  
  <pre><code>expression = xPath.compile("/Service/Inquiry/InquiryType/text()");
  </code></pre>
  
  <p>How can I write the accurate and complete java code for the above? I just want to extract the value for <code>&lt;InquiryType&gt;getParty&lt;/InquiryType&gt;</code>.</p>