<?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 Extracting names from fields in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/Extracting-names-from-fields/m-p/521180#M146835</link>
    <description>&lt;P&gt;Hi,&amp;nbsp;&lt;/P&gt;&lt;P&gt;I am trying to extract name of the individuals from the field that I have in the data. For example from the data below, I want to extract&amp;nbsp;Jack Smith and&amp;nbsp;Joe Shmoe.&amp;nbsp;&lt;/P&gt;&lt;P&gt;Any suggestions on how I can do this ?&amp;nbsp;&lt;/P&gt;&lt;P&gt;Some Text&lt;BR /&gt;Some Text&lt;BR /&gt;24-Jul-2020 10:52:41 - Jack Smith (Approval history)&lt;BR /&gt;Jack Smith approved INT128302 for group **CAB - DEV Tech&lt;BR /&gt;Some Text&lt;BR /&gt;Some Text&lt;BR /&gt;22-Jul-2020 12:56:37 - Joe Shmoe (Approval history)&lt;BR /&gt;Joe Shmoe approved INT128302 for group **Dev - DBA Tech group&lt;BR /&gt;Some Text&lt;BR /&gt;Some Text&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks !&amp;nbsp;&lt;/P&gt;&lt;P&gt;Rohan&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Thu, 24 Sep 2020 02:32:30 GMT</pubDate>
    <dc:creator>Rgk_Trail</dc:creator>
    <dc:date>2020-09-24T02:32:30Z</dc:date>
    <item>
      <title>Extracting names from fields</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Extracting-names-from-fields/m-p/521180#M146835</link>
      <description>&lt;P&gt;Hi,&amp;nbsp;&lt;/P&gt;&lt;P&gt;I am trying to extract name of the individuals from the field that I have in the data. For example from the data below, I want to extract&amp;nbsp;Jack Smith and&amp;nbsp;Joe Shmoe.&amp;nbsp;&lt;/P&gt;&lt;P&gt;Any suggestions on how I can do this ?&amp;nbsp;&lt;/P&gt;&lt;P&gt;Some Text&lt;BR /&gt;Some Text&lt;BR /&gt;24-Jul-2020 10:52:41 - Jack Smith (Approval history)&lt;BR /&gt;Jack Smith approved INT128302 for group **CAB - DEV Tech&lt;BR /&gt;Some Text&lt;BR /&gt;Some Text&lt;BR /&gt;22-Jul-2020 12:56:37 - Joe Shmoe (Approval history)&lt;BR /&gt;Joe Shmoe approved INT128302 for group **Dev - DBA Tech group&lt;BR /&gt;Some Text&lt;BR /&gt;Some Text&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thanks !&amp;nbsp;&lt;/P&gt;&lt;P&gt;Rohan&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 24 Sep 2020 02:32:30 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Extracting-names-from-fields/m-p/521180#M146835</guid>
      <dc:creator>Rgk_Trail</dc:creator>
      <dc:date>2020-09-24T02:32:30Z</dc:date>
    </item>
    <item>
      <title>Re: Extracting names from fields</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Extracting-names-from-fields/m-p/521212#M146849</link>
      <description>&lt;LI-CODE lang="markup"&gt;--- your search
| rex "-\s+(?&amp;lt;name&amp;gt;[^\(]+)"
| eval name=trim(name)&lt;/LI-CODE&gt;</description>
      <pubDate>Thu, 24 Sep 2020 07:21:17 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Extracting-names-from-fields/m-p/521212#M146849</guid>
      <dc:creator>ITWhisperer</dc:creator>
      <dc:date>2020-09-24T07:21:17Z</dc:date>
    </item>
    <item>
      <title>Re: Extracting names from fields</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Extracting-names-from-fields/m-p/521285#M146877</link>
      <description>&lt;P&gt;Would this work if names(&lt;SPAN&gt;Jack Smith)&lt;/SPAN&gt; and groups(&lt;SPAN&gt;**CAB - DEV Tech)&lt;/SPAN&gt; change ?&amp;nbsp;&lt;/P&gt;&lt;P&gt;Actually, I was not very clear in my initial question. So I want to extract name of the person and the group from that field.&amp;nbsp;&lt;/P&gt;&lt;P&gt;So format will remain the same but names and groups will change. Any idea if I can extract based on matching string and then extract text based on spaces in between ? cause format will remain the same in my data.&lt;/P&gt;&lt;P&gt;Thanks ,&lt;/P&gt;&lt;P&gt;Rohan&lt;/P&gt;</description>
      <pubDate>Thu, 24 Sep 2020 14:17:28 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Extracting-names-from-fields/m-p/521285#M146877</guid>
      <dc:creator>Rgk_Trail</dc:creator>
      <dc:date>2020-09-24T14:17:28Z</dc:date>
    </item>
    <item>
      <title>Re: Extracting names from fields</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Extracting-names-from-fields/m-p/521296#M146881</link>
      <description>&lt;P&gt;Are these all separate events or does every event start with a timestamp but can be multi-line?&lt;/P&gt;&lt;P&gt;Does the group name always start with **?&lt;/P&gt;&lt;P&gt;Does every line with name and group always have "approved" and "for group" in?&lt;/P&gt;</description>
      <pubDate>Thu, 24 Sep 2020 14:47:02 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Extracting-names-from-fields/m-p/521296#M146881</guid>
      <dc:creator>ITWhisperer</dc:creator>
      <dc:date>2020-09-24T14:47:02Z</dc:date>
    </item>
    <item>
      <title>Re: Extracting names from fields</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Extracting-names-from-fields/m-p/521322#M146897</link>
      <description>&lt;P&gt;&lt;SPAN&gt;Are these all separate events or does every event start with a timestamp but can be multi-line?&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Every event starts with timestamp, and its multi-line. for every event name and group is buried between some other information that is not relevant for the task.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Does the group name always start with **?&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Ya. Always&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Does every line with name and group always have "approved" and "for group" in?&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Yes. Always. It may have "rejected" as well but I want to extract only one with "approved"&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 24 Sep 2020 16:24:03 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Extracting-names-from-fields/m-p/521322#M146897</guid>
      <dc:creator>Rgk_Trail</dc:creator>
      <dc:date>2020-09-24T16:24:03Z</dc:date>
    </item>
    <item>
      <title>Re: Extracting names from fields</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Extracting-names-from-fields/m-p/521323#M146898</link>
      <description>&lt;P&gt;-- your search&lt;/P&gt;&lt;P&gt;| rex "\n(?&amp;lt;name&amp;gt;.+)\sapproved\s.+for\sgroup\s(?&amp;lt;group&amp;gt;.+)\n"&lt;/P&gt;</description>
      <pubDate>Thu, 24 Sep 2020 16:31:25 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Extracting-names-from-fields/m-p/521323#M146898</guid>
      <dc:creator>ITWhisperer</dc:creator>
      <dc:date>2020-09-24T16:31:25Z</dc:date>
    </item>
    <item>
      <title>Re: Extracting names from fields</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Extracting-names-from-fields/m-p/521475#M146956</link>
      <description>&lt;P&gt;I am trying this command but it doesnt return any results, am i using it wrong ?&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;|inputlookup change_task_xx| rex "\n(?&amp;lt;name&amp;gt;.+)\sapproved\s.+for\sgroup\s(?&amp;lt;group&amp;gt;.+)\n"|table change_request name group&lt;/P&gt;&lt;P&gt;Output that I am getting:&amp;nbsp;&lt;/P&gt;&lt;P&gt;change_requests&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;name&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; group&lt;/P&gt;&lt;P&gt;1&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;&lt;/P&gt;&lt;P&gt;2&lt;/P&gt;&lt;P&gt;3&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;name and group information exists in the field(approval) in the lookup .&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;- Rohan K.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 25 Sep 2020 14:48:23 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Extracting-names-from-fields/m-p/521475#M146956</guid>
      <dc:creator>Rgk_Trail</dc:creator>
      <dc:date>2020-09-25T14:48:23Z</dc:date>
    </item>
    <item>
      <title>Re: Extracting names from fields</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Extracting-names-from-fields/m-p/521487#M146961</link>
      <description>&lt;P&gt;Try this:&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;|inputlookup change_task_xx| rex field=approval "\n(?&amp;lt;name&amp;gt;.+)\sapproved\s.+for\sgroup\s(?&amp;lt;group&amp;gt;.+)\n"|table change_request name group
&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 25 Sep 2020 15:17:35 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Extracting-names-from-fields/m-p/521487#M146961</guid>
      <dc:creator>s2_splunk</dc:creator>
      <dc:date>2020-09-25T15:17:35Z</dc:date>
    </item>
    <item>
      <title>Re: Extracting names from fields</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Extracting-names-from-fields/m-p/521488#M146962</link>
      <description>&lt;P&gt;Does your table include the multi-line events as single events or have they been split across multiple events?&lt;/P&gt;</description>
      <pubDate>Fri, 25 Sep 2020 15:23:08 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Extracting-names-from-fields/m-p/521488#M146962</guid>
      <dc:creator>ITWhisperer</dc:creator>
      <dc:date>2020-09-25T15:23:08Z</dc:date>
    </item>
    <item>
      <title>Re: Extracting names from fields</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Extracting-names-from-fields/m-p/521530#M146979</link>
      <description>&lt;P&gt;attached data from lookup.&amp;nbsp;&lt;/P&gt;&lt;P&gt;its multiline as single event. Its tied to unique field (change_request) in dataset. So goal is to extract change_request and name, group from approval for that change request.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 25 Sep 2020 17:27:07 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Extracting-names-from-fields/m-p/521530#M146979</guid>
      <dc:creator>Rgk_Trail</dc:creator>
      <dc:date>2020-09-25T17:27:07Z</dc:date>
    </item>
    <item>
      <title>Re: Extracting names from fields</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Extracting-names-from-fields/m-p/521631#M147003</link>
      <description>&lt;P&gt;Thanks a lot !&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sun, 27 Sep 2020 00:07:22 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Extracting-names-from-fields/m-p/521631#M147003</guid>
      <dc:creator>Rgk_Trail</dc:creator>
      <dc:date>2020-09-27T00:07:22Z</dc:date>
    </item>
  </channel>
</rss>

