some normal text.......and in between
<ns0:ExceptionLog_Action>
<ns0:Exception>
<ns0:Code>111</ns0:Code>
<ns0:Reason>ErrorCode: Life-003
Reason: Mapping error in Web Service 
Stacktrace...(other sub-fields)</ns0:Reason>
</ns0:Exception>
</ns0:ExceptionLog_Action>
I want the value of Reason: inside <ns0:Reason>
before 
that is : Mapping error in Web Service
Please help me to do so.
Thanks In Advance
Vaibhav Vijay
Hello Vaibhav,
I can see that "Mapping error in Web Service" is prefixed by "Reason:"
With that in mind, check out this regex:
Reason: (?<Reason>[^&]+) 
This is how you can verify:
| makeresults count=1
| eval _raw="some normal text.......and in between <ns0:ExceptionLog_Action> <ns0:Exception> <ns0:Code>111</ns0:Code> <ns0:Reason>ErrorCode: Life-003
Reason: Mapping error in Web Service 
Stacktrace...(other sub-fields)</ns0:Reason> </ns0:Exception> </ns0:ExceptionLog_Action>"
| rex field=_raw "Reason: (?<Reason>[^&]+) 
"
Hello Vaibhav,
I can see that "Mapping error in Web Service" is prefixed by "Reason:"
With that in mind, check out this regex:
Reason: (?<Reason>[^&]+) 
This is how you can verify:
| makeresults count=1
| eval _raw="some normal text.......and in between <ns0:ExceptionLog_Action> <ns0:Exception> <ns0:Code>111</ns0:Code> <ns0:Reason>ErrorCode: Life-003
Reason: Mapping error in Web Service 
Stacktrace...(other sub-fields)</ns0:Reason> </ns0:Exception> </ns0:ExceptionLog_Action>"
| rex field=_raw "Reason: (?<Reason>[^&]+) 
"
Thanks a lot Whrg!!
I am really grateful for your help, it has been incredibly helpful to me.
Regards,
Vaibhav Vijay