<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Extract a string from a field using regex. in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/Extract-a-string-from-a-field-using-regex/m-p/437477#M124559</link>
    <description>&lt;P&gt;Thanks Frank!&lt;/P&gt;

&lt;P&gt;It works now. &lt;/P&gt;</description>
    <pubDate>Fri, 19 Oct 2018 04:39:26 GMT</pubDate>
    <dc:creator>NicoloPunzalan2</dc:creator>
    <dc:date>2018-10-19T04:39:26Z</dc:date>
    <item>
      <title>Extract a string from a field using regex.</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Extract-a-string-from-a-field-using-regex/m-p/437474#M124556</link>
      <description>&lt;P&gt;Hi All,&lt;/P&gt;

&lt;P&gt;I am having an issue on extracting a string in a field. For example, I have this data below:&lt;/P&gt;

&lt;P&gt;"18/10/2018 03:44:35 - Joneil Englis (Additional comments) Hi All, this is now being investigated. We'll keep you updated on our progress. 16/10/2018 04:40:51 - David Jinn Hong Chia (Additional comments) Hi team Another Shipment Cost Document has the same issue in E1P today. 563638 15/10/2018 02:21:06 - Christian Espinosa (Additional comments) Hi All, this is now being investigated. We'll keep you updated on our progress. "&lt;/P&gt;

&lt;P&gt;I need to get the latest name on who updated the ticket. I am trying to use a regex expression where i can get the string between the character "-" and "(" but sometimes the data of the field contains many occurrence of these characters.&lt;/P&gt;

&lt;P&gt;I need to get the string Joneil Englis. Could anyone help me?&lt;/P&gt;

&lt;P&gt;Thanks in advance.&lt;/P&gt;</description>
      <pubDate>Thu, 18 Oct 2018 06:55:38 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Extract-a-string-from-a-field-using-regex/m-p/437474#M124556</guid>
      <dc:creator>NicoloPunzalan2</dc:creator>
      <dc:date>2018-10-18T06:55:38Z</dc:date>
    </item>
    <item>
      <title>Re: Extract a string from a field using regex.</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Extract-a-string-from-a-field-using-regex/m-p/437475#M124557</link>
      <description>&lt;P&gt;If the latest occurrence is always at the start, it is fairly straightforward:&lt;/P&gt;

&lt;P&gt;&lt;CODE&gt;^"\d+\/\d+\/\d+\s+\d+:\d+:\d+\s+-\s+(?&amp;lt;name&amp;gt;[^\(]+)\s+\(&lt;/CODE&gt;&lt;BR /&gt;
&lt;A href="https://regex101.com/r/70N4wf/1"&gt;https://regex101.com/r/70N4wf/1&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 18 Oct 2018 07:28:47 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Extract-a-string-from-a-field-using-regex/m-p/437475#M124557</guid>
      <dc:creator>FrankVl</dc:creator>
      <dc:date>2018-10-18T07:28:47Z</dc:date>
    </item>
    <item>
      <title>Re: Extract a string from a field using regex.</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Extract-a-string-from-a-field-using-regex/m-p/437476#M124558</link>
      <description>&lt;P&gt;I modified the regex a little so that it will take less steps to find the match.&lt;/P&gt;

&lt;P&gt;This is the regex: &lt;CODE&gt;^"[\d\/\s\:]+-\s+(?&amp;lt;name&amp;gt;[\w\s]+)&lt;/CODE&gt;&lt;BR /&gt;
&lt;A href="https://regex101.com/r/70N4wf/3"&gt;https://regex101.com/r/70N4wf/3&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 18 Oct 2018 16:45:57 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Extract-a-string-from-a-field-using-regex/m-p/437476#M124558</guid>
      <dc:creator>sudosplunk</dc:creator>
      <dc:date>2018-10-18T16:45:57Z</dc:date>
    </item>
    <item>
      <title>Re: Extract a string from a field using regex.</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Extract-a-string-from-a-field-using-regex/m-p/437477#M124559</link>
      <description>&lt;P&gt;Thanks Frank!&lt;/P&gt;

&lt;P&gt;It works now. &lt;/P&gt;</description>
      <pubDate>Fri, 19 Oct 2018 04:39:26 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Extract-a-string-from-a-field-using-regex/m-p/437477#M124559</guid>
      <dc:creator>NicoloPunzalan2</dc:creator>
      <dc:date>2018-10-19T04:39:26Z</dc:date>
    </item>
    <item>
      <title>Re: Extract a string from a field using regex.</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Extract-a-string-from-a-field-using-regex/m-p/437478#M124560</link>
      <description>&lt;P&gt;Dangerous assumption that names don't contain anything but alphanumeric and spaces. Also, yours captures the trailing space behind the name (not sure if Splunk will automatically trim that perhaps?).&lt;/P&gt;

&lt;P&gt;But the part before the name is indeed more efficient like this, thanks &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 19 Oct 2018 06:43:34 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Extract-a-string-from-a-field-using-regex/m-p/437478#M124560</guid>
      <dc:creator>FrankVl</dc:creator>
      <dc:date>2018-10-19T06:43:34Z</dc:date>
    </item>
  </channel>
</rss>

