title: How can I use substring string function in MVEL expressions
body: <p>I am using Studio and have a need to use MVEL expressions. Can someone please tell me how can I extract all the characters in a field after underscore character.I am reading these values from an XML file.Please see below example.</p>
  
  <p>Action:</p>
  
  <pre><code>NEW_3456
  NEW_CW234789
  </code></pre>
  
  <p>So, I want my MVEL expresion to extract all the values after underscore. So, the result for the above expression should be <code>3456</code> and <code>CW234789</code> respectively.</p>
  
  <p>Here is what I am using :
  Declare a variable to navigate and pick the Action field value.</p>
  
  <p>Lets say the variable declared is </p>
  
  <pre><code>props['applicant.Status1'] 
  </code></pre>
  
  <p>The value of this variable is  :</p>
  
  <pre><code>props['applicant.Status1'] = parts[0].xpath('/row/Action/normalize-space(substring(text(),5,8))')
  </code></pre>
  
  <p>The output is <code>3456</code> and <code>CW23</code> which is fine.</p>
  
  <p>Now here is the issue, in order to extract all the value aftre underscore  I used the below expression and I am not getting the deired value.</p>
  
  <pre><code>props['applicant.Status1'] = parts[0].xpath('/row/Action/normalize-space(substring-after(text(),5))')
  </code></pre>
  
  <p>Can someone please tell me if the above expresion is correct. Is there some other way I can get the value I am desiring. Thanks!</p>