<?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: regex remove events from search in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/regex-remove-events-from-search/m-p/380100#M111280</link>
    <description>&lt;P&gt;Try this:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;| inputlookup mylookup 
| regex host!="^\d{1,3}.\d{1,3}.\d{1,3}.\d{1,3}$"
| table host
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;You just had to remove the &lt;CODE&gt;/&lt;/CODE&gt; at the start and end &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;

&lt;P&gt;Hope that helps - if it does I'd be happy if you would upvote/accept this answer, so others could profit from it. &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;</description>
    <pubDate>Wed, 02 May 2018 14:32:03 GMT</pubDate>
    <dc:creator>xpac</dc:creator>
    <dc:date>2018-05-02T14:32:03Z</dc:date>
    <item>
      <title>regex remove events from search</title>
      <link>https://community.splunk.com/t5/Splunk-Search/regex-remove-events-from-search/m-p/380099#M111279</link>
      <description>&lt;P&gt;I'm reading in events from a lookup table and I'm trying to remove events using RegEx that meet criteria but can't get it to work. I want to remove any host that is an IP address.&lt;/P&gt;

&lt;P&gt;lookup file:&lt;BR /&gt;
host&lt;BR /&gt;
x.x.x.x&lt;BR /&gt;
hosta&lt;BR /&gt;
x.x.x.x&lt;BR /&gt;
hostb&lt;/P&gt;

&lt;P&gt;| inputlookup mylookup&lt;BR /&gt;&lt;BR /&gt;
| regex host!="/^\d{1,3}.\d{1,3}.\d{1,3}.\d{1,3}$/"&lt;BR /&gt;
| table host&lt;/P&gt;

&lt;P&gt;With this I still get all events. thx.&lt;/P&gt;</description>
      <pubDate>Wed, 02 May 2018 14:25:27 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/regex-remove-events-from-search/m-p/380099#M111279</guid>
      <dc:creator>brdr</dc:creator>
      <dc:date>2018-05-02T14:25:27Z</dc:date>
    </item>
    <item>
      <title>Re: regex remove events from search</title>
      <link>https://community.splunk.com/t5/Splunk-Search/regex-remove-events-from-search/m-p/380100#M111280</link>
      <description>&lt;P&gt;Try this:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;| inputlookup mylookup 
| regex host!="^\d{1,3}.\d{1,3}.\d{1,3}.\d{1,3}$"
| table host
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;You just had to remove the &lt;CODE&gt;/&lt;/CODE&gt; at the start and end &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;

&lt;P&gt;Hope that helps - if it does I'd be happy if you would upvote/accept this answer, so others could profit from it. &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 02 May 2018 14:32:03 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/regex-remove-events-from-search/m-p/380100#M111280</guid>
      <dc:creator>xpac</dc:creator>
      <dc:date>2018-05-02T14:32:03Z</dc:date>
    </item>
    <item>
      <title>Re: regex remove events from search</title>
      <link>https://community.splunk.com/t5/Splunk-Search/regex-remove-events-from-search/m-p/380101#M111281</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;

&lt;P&gt;You can also use the regex OR match function:&lt;/P&gt;

&lt;P&gt;match:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;   , | inputlookup mylookup 
     | where !match(host,"(\d{1,3}\.){3}\d+")
     | table host
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Regex:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt; | inputlookup mylookup 
 | regex host!="^(\d{1,3}\.){3}\d{1,3}$"
 | table host
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Wed, 02 May 2018 14:40:34 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/regex-remove-events-from-search/m-p/380101#M111281</guid>
      <dc:creator>TISKAR</dc:creator>
      <dc:date>2018-05-02T14:40:34Z</dc:date>
    </item>
    <item>
      <title>Re: regex remove events from search</title>
      <link>https://community.splunk.com/t5/Splunk-Search/regex-remove-events-from-search/m-p/380102#M111282</link>
      <description>&lt;P&gt;Thanks TISKAR, xpac for response!&lt;/P&gt;</description>
      <pubDate>Wed, 02 May 2018 14:47:31 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/regex-remove-events-from-search/m-p/380102#M111282</guid>
      <dc:creator>brdr</dc:creator>
      <dc:date>2018-05-02T14:47:31Z</dc:date>
    </item>
  </channel>
</rss>

