<?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 Rex field in Splunk Enterprise</title>
    <link>https://community.splunk.com/t5/Splunk-Enterprise/Rex-field/m-p/574929#M10708</link>
    <description>&lt;P&gt;I want to extract the Country and the Node. When I use the rex in regex101, it works fine. But when I put it on Splunk search, it did not extract the Country and the Node. Do you guys know where is my mistake?&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="fortinet.PNG" style="width: 999px;"&gt;&lt;img src="https://community.splunk.com/t5/image/serverpage/image-id/16864iBC219A558454EEF7/image-size/large?v=v2&amp;amp;px=999" role="button" title="fortinet.PNG" alt="fortinet.PNG" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;This is my search query.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;index="maxis_csaroam_index" source="/home/csaops/csaroam/*_MOS.csv" 
| dedup Description
| table Description
| rex field=Description "(?&amp;lt;Country&amp;gt;[\w]+)(?&amp;lt;Node&amp;gt;[\w\- ]*\n)"&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Mon, 15 Nov 2021 14:01:18 GMT</pubDate>
    <dc:creator>Azwaliyana</dc:creator>
    <dc:date>2021-11-15T14:01:18Z</dc:date>
    <item>
      <title>Rex field</title>
      <link>https://community.splunk.com/t5/Splunk-Enterprise/Rex-field/m-p/574929#M10708</link>
      <description>&lt;P&gt;I want to extract the Country and the Node. When I use the rex in regex101, it works fine. But when I put it on Splunk search, it did not extract the Country and the Node. Do you guys know where is my mistake?&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="fortinet.PNG" style="width: 999px;"&gt;&lt;img src="https://community.splunk.com/t5/image/serverpage/image-id/16864iBC219A558454EEF7/image-size/large?v=v2&amp;amp;px=999" role="button" title="fortinet.PNG" alt="fortinet.PNG" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;This is my search query.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;index="maxis_csaroam_index" source="/home/csaops/csaroam/*_MOS.csv" 
| dedup Description
| table Description
| rex field=Description "(?&amp;lt;Country&amp;gt;[\w]+)(?&amp;lt;Node&amp;gt;[\w\- ]*\n)"&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 15 Nov 2021 14:01:18 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Enterprise/Rex-field/m-p/574929#M10708</guid>
      <dc:creator>Azwaliyana</dc:creator>
      <dc:date>2021-11-15T14:01:18Z</dc:date>
    </item>
    <item>
      <title>Re: Rex field</title>
      <link>https://community.splunk.com/t5/Splunk-Enterprise/Rex-field/m-p/574938#M10709</link>
      <description>&lt;P&gt;Try without the newline in the match&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;| rex field=Description "(?&amp;lt;Country&amp;gt;[\w]+)(?&amp;lt;Node&amp;gt;[\w\- ]+)"&lt;/LI-CODE&gt;</description>
      <pubDate>Mon, 15 Nov 2021 14:46:37 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Enterprise/Rex-field/m-p/574938#M10709</guid>
      <dc:creator>ITWhisperer</dc:creator>
      <dc:date>2021-11-15T14:46:37Z</dc:date>
    </item>
    <item>
      <title>Re: Rex field</title>
      <link>https://community.splunk.com/t5/Splunk-Enterprise/Rex-field/m-p/574948#M10710</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/240128"&gt;@Azwaliyana&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;&lt;P&gt;Try this.&lt;/P&gt;&lt;P&gt;&lt;FONT color="#000080"&gt;&lt;STRONG&gt;| rex field=Description "(?&amp;lt;Country&amp;gt;\w+)\s(?&amp;lt;Node&amp;gt;\w*\-?\w+)"&lt;/STRONG&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="bhargavi_0-1636995231697.png" style="width: 400px;"&gt;&lt;img src="https://community.splunk.com/t5/image/serverpage/image-id/16865iF018EB600035C369/image-size/medium?v=v2&amp;amp;px=400" role="button" title="bhargavi_0-1636995231697.png" alt="bhargavi_0-1636995231697.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 15 Nov 2021 16:54:09 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Enterprise/Rex-field/m-p/574948#M10710</guid>
      <dc:creator>bhargavi</dc:creator>
      <dc:date>2021-11-15T16:54:09Z</dc:date>
    </item>
    <item>
      <title>Re: Rex field</title>
      <link>https://community.splunk.com/t5/Splunk-Enterprise/Rex-field/m-p/575055#M10718</link>
      <description>&lt;P&gt;Give this a try (avoided using dedup command as well, best practice)&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;index="maxis_csaroam_index" source="/home/csaops/csaroam/*_MOS.csv" 
| stats count by Description
| table Description
| rex field=Description "(?&amp;lt;Country&amp;gt;\S+)\s+(?&amp;lt;Node&amp;gt;\S+)"&lt;/LI-CODE&gt;</description>
      <pubDate>Tue, 16 Nov 2021 14:16:32 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Enterprise/Rex-field/m-p/575055#M10718</guid>
      <dc:creator>somesoni2</dc:creator>
      <dc:date>2021-11-16T14:16:32Z</dc:date>
    </item>
  </channel>
</rss>

