<?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: Splunk  filter data NOT IN subquery in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/Why-Splunk-filter-data-NOT-IN-subquery/m-p/595213#M207137</link>
    <description>&lt;P&gt;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/225168"&gt;@ITWhisperer&lt;/a&gt;&amp;nbsp;So for these 2 Events&amp;nbsp;EXTERNAL_API OR EXTERNAL_STATUS. I am getting a url something like this&amp;nbsp;/api/sns/exts/djs/310200019110274535/ds/310200019110274536/ and&amp;nbsp; variable is the value which I am extracting from this url which is&amp;nbsp;310200019110274535 in this case&lt;/P&gt;</description>
    <pubDate>Mon, 25 Apr 2022 13:58:05 GMT</pubDate>
    <dc:creator>marcosjags</dc:creator>
    <dc:date>2022-04-25T13:58:05Z</dc:date>
    <item>
      <title>Why Splunk filter data NOT IN subquery?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Why-Splunk-filter-data-NOT-IN-subquery/m-p/595156#M207111</link>
      <description>&lt;P&gt;index=xt DONT_MATCH | spath input=log path=message.extra.dj output=dj | spath input=log output=fname path=message.msg.fname| search dj=* NOT [search EXTERNAL_API OR EXTERNAL_STATUS | spath input=log output=url path=url | dedup url | rex field=url "^(\/\w+){6}\/(?&amp;lt;variable&amp;gt;\d+)" | table url variable | stats list(variable) as variable] | stats count by fname&lt;/P&gt;
&lt;P&gt;The task here is to show the &lt;STRONG&gt;dj&lt;/STRONG&gt; which is there in this event &lt;STRONG&gt;DONT_MATCH&lt;/STRONG&gt; and it should not show those dj if it occurs in these 2 events &lt;STRONG&gt;EXTERNAL_API OR EXTERNAL_STATUS&lt;/STRONG&gt;. So basically I want to show all the DJ which is there in &lt;STRONG&gt;DONT_MATCH&lt;/STRONG&gt; and &lt;STRONG&gt;NOT IN EXTERNAL_API OR EXTERNAL_STATUS&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 25 Apr 2022 15:25:04 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Why-Splunk-filter-data-NOT-IN-subquery/m-p/595156#M207111</guid>
      <dc:creator>marcosjags</dc:creator>
      <dc:date>2022-04-25T15:25:04Z</dc:date>
    </item>
    <item>
      <title>Re: Splunk  filter data NOT IN subquery</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Why-Splunk-filter-data-NOT-IN-subquery/m-p/595161#M207113</link>
      <description>&lt;P&gt;That's a bit unclear. You search for something called DONT_MATCH, in the subsearch you're tabling two fields only to count one of them and completely discard the other one.&lt;/P&gt;&lt;P&gt;Be a bit more specific what your events look like and what you want to achieve. It would be most desirable to do it without subsearches if possible.&lt;/P&gt;</description>
      <pubDate>Mon, 25 Apr 2022 09:58:18 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Why-Splunk-filter-data-NOT-IN-subquery/m-p/595161#M207113</guid>
      <dc:creator>PickleRick</dc:creator>
      <dc:date>2022-04-25T09:58:18Z</dc:date>
    </item>
    <item>
      <title>Re: Splunk  filter data NOT IN subquery</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Why-Splunk-filter-data-NOT-IN-subquery/m-p/595165#M207116</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/231884"&gt;@PickleRick&lt;/a&gt;&amp;nbsp; Actually there are 3 events name&amp;nbsp;&lt;/P&gt;&lt;P&gt;1. DONT_MATCH&lt;/P&gt;&lt;P&gt;2.&amp;nbsp;EXTERNAL_API&amp;nbsp;&lt;/P&gt;&lt;P&gt;3. EXTERNAL_STATUS&lt;/P&gt;&lt;P&gt;So I want to get values from the first event only. So I am filtering the DJ which I get in all the 3 events. What I want here is if the DJ is there in First event then ideally it should not be there in the other two and it should show all the values related to that DJ which will eventually help me in creating charts.&lt;/P&gt;</description>
      <pubDate>Mon, 25 Apr 2022 10:12:04 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Why-Splunk-filter-data-NOT-IN-subquery/m-p/595165#M207116</guid>
      <dc:creator>marcosjags</dc:creator>
      <dc:date>2022-04-25T10:12:04Z</dc:date>
    </item>
    <item>
      <title>Re: Splunk  filter data NOT IN subquery</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Why-Splunk-filter-data-NOT-IN-subquery/m-p/595174#M207121</link>
      <description>&lt;P&gt;Ahhh, so they are literal constants included in the events, not some placeholders you use to obfuscate parts of your search? &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;&lt;P&gt;It's still not clear what is the relation between separate events. What comes to mind first is a simple&lt;/P&gt;&lt;PRE&gt;index=xt DONT_MATCH NOT EXTERNAL_API NOT EXTERNAL_STATUS | all that spath stuff.&lt;/PRE&gt;&lt;P&gt;But I'm not sure if that's what you want. I suppose not. There is some identifier (dj?) that occurs in those events and each of those events can have either of those 3 names? And you want only those events for which (for single dj) you have an even with "DONT_MATCH" but don't have another event with the same dj which contains EXTERNAL_AP or EXTERNAL_STATUS?&lt;/P&gt;&lt;P&gt;Be a bit more specific.&lt;/P&gt;</description>
      <pubDate>Mon, 25 Apr 2022 10:46:56 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Why-Splunk-filter-data-NOT-IN-subquery/m-p/595174#M207121</guid>
      <dc:creator>PickleRick</dc:creator>
      <dc:date>2022-04-25T10:46:56Z</dc:date>
    </item>
    <item>
      <title>Re: Splunk  filter data NOT IN subquery</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Why-Splunk-filter-data-NOT-IN-subquery/m-p/595176#M207123</link>
      <description>&lt;P&gt;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/231884"&gt;@PickleRick&lt;/a&gt;&amp;nbsp; These separate events are having dj which is common for all the 3 events.&amp;nbsp;&lt;/P&gt;&lt;P&gt;if I do&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;index=xt DONT_MATCH NOT EXTERNAL_API NOT EXTERNAL_STATUS | all that spath stuff&lt;/PRE&gt;&lt;P&gt;Then also it will pull the DJ which at some point of time exists in all the 3. So what I want here is to pull all the DJ which is there in First even i.e DONT_MATCH and Does not exist in other 2. This is the expectation here. To fetch all the DJ from 1st event which does not exist in other 2.&lt;/P&gt;</description>
      <pubDate>Mon, 25 Apr 2022 11:26:53 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Why-Splunk-filter-data-NOT-IN-subquery/m-p/595176#M207123</guid>
      <dc:creator>marcosjags</dc:creator>
      <dc:date>2022-04-25T11:26:53Z</dc:date>
    </item>
    <item>
      <title>Re: Splunk  filter data NOT IN subquery</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Why-Splunk-filter-data-NOT-IN-subquery/m-p/595177#M207124</link>
      <description>&lt;P&gt;It is not clear how you are identifying events which match DONT_MATCH but don't match events which match EXTERNAL_API or EXTERNAL_STATUS.&lt;/P&gt;&lt;P&gt;Do your events already have a field called variable or url when they match DONT_MATCH?&lt;/P&gt;</description>
      <pubDate>Mon, 25 Apr 2022 11:37:27 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Why-Splunk-filter-data-NOT-IN-subquery/m-p/595177#M207124</guid>
      <dc:creator>ITWhisperer</dc:creator>
      <dc:date>2022-04-25T11:37:27Z</dc:date>
    </item>
    <item>
      <title>Re: Splunk  filter data NOT IN subquery</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Why-Splunk-filter-data-NOT-IN-subquery/m-p/595206#M207134</link>
      <description>&lt;P&gt;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/225168"&gt;@ITWhisperer&lt;/a&gt;&amp;nbsp;I am trying to&amp;nbsp; filter all the events which matches&amp;nbsp;&lt;SPAN&gt;DONT_MATCH using DJ and then I am trying to filter DJ from EXTERNAL_API or EXTERNAL_STATUS and the one which will not match the DJ from EXTERNAL_API or EXTERNAL_STATUS&amp;nbsp;should be my expected DJ. basically A same DJ can be in all the 3 events. What I want is only those DT which are in event DONT_MATCH and NOT IN&amp;nbsp;EXTERNAL_API or EXTERNAL_STATUS&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 25 Apr 2022 13:11:15 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Why-Splunk-filter-data-NOT-IN-subquery/m-p/595206#M207134</guid>
      <dc:creator>marcosjags</dc:creator>
      <dc:date>2022-04-25T13:11:15Z</dc:date>
    </item>
    <item>
      <title>Re: Splunk  filter data NOT IN subquery</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Why-Splunk-filter-data-NOT-IN-subquery/m-p/595212#M207136</link>
      <description>&lt;P&gt;So, what does url and variable have to do with this?&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;index=xt DONT_MATCH | spath input=log path=message.extra.dj output=dj | spath input=log output=fname path=message.msg.fname| search dj=* NOT [search EXTERNAL_API OR EXTERNAL_STATUS | spath input=log path=message.extra.dj output=dj | table dj] | stats count by fname&lt;/LI-CODE&gt;</description>
      <pubDate>Mon, 25 Apr 2022 13:51:27 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Why-Splunk-filter-data-NOT-IN-subquery/m-p/595212#M207136</guid>
      <dc:creator>ITWhisperer</dc:creator>
      <dc:date>2022-04-25T13:51:27Z</dc:date>
    </item>
    <item>
      <title>Re: Splunk  filter data NOT IN subquery</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Why-Splunk-filter-data-NOT-IN-subquery/m-p/595213#M207137</link>
      <description>&lt;P&gt;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/225168"&gt;@ITWhisperer&lt;/a&gt;&amp;nbsp;So for these 2 Events&amp;nbsp;EXTERNAL_API OR EXTERNAL_STATUS. I am getting a url something like this&amp;nbsp;/api/sns/exts/djs/310200019110274535/ds/310200019110274536/ and&amp;nbsp; variable is the value which I am extracting from this url which is&amp;nbsp;310200019110274535 in this case&lt;/P&gt;</description>
      <pubDate>Mon, 25 Apr 2022 13:58:05 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Why-Splunk-filter-data-NOT-IN-subquery/m-p/595213#M207137</guid>
      <dc:creator>marcosjags</dc:creator>
      <dc:date>2022-04-25T13:58:05Z</dc:date>
    </item>
    <item>
      <title>Re: Splunk  filter data NOT IN subquery</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Why-Splunk-filter-data-NOT-IN-subquery/m-p/595215#M207138</link>
      <description>&lt;P&gt;How does this relate to the events you are getting with the DONT_MATCH search?&lt;/P&gt;&lt;P&gt;You don't appear to have a url or variable field extracted by the first part of the search&lt;/P&gt;</description>
      <pubDate>Mon, 25 Apr 2022 14:05:24 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Why-Splunk-filter-data-NOT-IN-subquery/m-p/595215#M207138</guid>
      <dc:creator>ITWhisperer</dc:creator>
      <dc:date>2022-04-25T14:05:24Z</dc:date>
    </item>
    <item>
      <title>Re: Splunk  filter data NOT IN subquery</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Why-Splunk-filter-data-NOT-IN-subquery/m-p/595216#M207139</link>
      <description>&lt;P&gt;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/225168"&gt;@ITWhisperer&lt;/a&gt;&amp;nbsp; SO in first part of the search I am getting DJ directly in my splunk log but for the&amp;nbsp; other 2 events I am getting in url.&amp;nbsp;&lt;/P&gt;&lt;P&gt;for DONT_MATCH i am getting it as&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;SPAN class=""&gt;&lt;SPAN&gt;{"&lt;/SPAN&gt;log&lt;SPAN&gt;"&lt;/SPAN&gt;:&lt;SPAN&gt;"{&lt;/SPAN&gt;&lt;SPAN&gt;"&lt;/SPAN&gt;logtime&lt;SPAN&gt;"&lt;/SPAN&gt;: &lt;SPAN&gt;"&lt;/SPAN&gt;2022-04-25T09:53:47.629&lt;SPAN&gt;", &lt;/SPAN&gt;&lt;SPAN&gt;"&lt;/SPAN&gt;level&lt;SPAN&gt;"&lt;/SPAN&gt;: &lt;SPAN&gt;"[&lt;/SPAN&gt;INFO&lt;SPAN&gt;]&lt;/SPAN&gt;&lt;SPAN&gt;",&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN&gt;"dj&lt;/SPAN&gt;&lt;SPAN&gt;"&lt;/SPAN&gt;&lt;SPAN class=""&gt;:&lt;/SPAN&gt; &lt;SPAN&gt;"&lt;/SPAN&gt;&lt;SPAN class=""&gt;310200019098846363"}}&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 25 Apr 2022 14:10:48 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Why-Splunk-filter-data-NOT-IN-subquery/m-p/595216#M207139</guid>
      <dc:creator>marcosjags</dc:creator>
      <dc:date>2022-04-25T14:10:48Z</dc:date>
    </item>
    <item>
      <title>Re: Splunk  filter data NOT IN subquery</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Why-Splunk-filter-data-NOT-IN-subquery/m-p/595217#M207140</link>
      <description>&lt;P&gt;OK so for the filtering to work, the field names should probably match - try it this way&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;index=xt DONT_MATCH | spath input=log path=message.extra.dj output=dj | spath input=log output=fname path=message.msg.fname| search dj=* NOT [search EXTERNAL_API OR EXTERNAL_STATUS | spath input=log output=url path=url | dedup url | rex field=url "^(\/\w+){6}\/(?&amp;lt;dj&amp;gt;\d+)" | table dj] | stats count by fname&lt;/LI-CODE&gt;</description>
      <pubDate>Mon, 25 Apr 2022 14:14:53 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Why-Splunk-filter-data-NOT-IN-subquery/m-p/595217#M207140</guid>
      <dc:creator>ITWhisperer</dc:creator>
      <dc:date>2022-04-25T14:14:53Z</dc:date>
    </item>
    <item>
      <title>Re: Splunk  filter data NOT IN subquery</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Why-Splunk-filter-data-NOT-IN-subquery/m-p/595221#M207141</link>
      <description>&lt;P&gt;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/225168"&gt;@ITWhisperer&lt;/a&gt;&amp;nbsp;I have tried this way. But it is&amp;nbsp; still fetching the data from all&amp;nbsp; the events . it is not excluding the other 2 events&lt;/P&gt;</description>
      <pubDate>Mon, 25 Apr 2022 14:27:45 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Why-Splunk-filter-data-NOT-IN-subquery/m-p/595221#M207141</guid>
      <dc:creator>marcosjags</dc:creator>
      <dc:date>2022-04-25T14:27:45Z</dc:date>
    </item>
    <item>
      <title>Re: Splunk  filter data NOT IN subquery</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Why-Splunk-filter-data-NOT-IN-subquery/m-p/595224#M207143</link>
      <description>&lt;P&gt;Can you give an example of an event which should not be there together with the event which should have knocked it out?&lt;/P&gt;</description>
      <pubDate>Mon, 25 Apr 2022 14:38:23 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Why-Splunk-filter-data-NOT-IN-subquery/m-p/595224#M207143</guid>
      <dc:creator>ITWhisperer</dc:creator>
      <dc:date>2022-04-25T14:38:23Z</dc:date>
    </item>
    <item>
      <title>Re: Splunk  filter data NOT IN subquery</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Why-Splunk-filter-data-NOT-IN-subquery/m-p/595253#M207153</link>
      <description>&lt;P&gt;You could try using subsearch to find values of dj to exclude but if your set of events to process is relatively large, it can cause problems. Even worse - you will not know there were problems, you would just get wrong results. Also, if you only want some statistical summary, not whole levels, you could get by some clever groupping and stats I believe.&lt;/P&gt;</description>
      <pubDate>Mon, 25 Apr 2022 16:34:22 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Why-Splunk-filter-data-NOT-IN-subquery/m-p/595253#M207153</guid>
      <dc:creator>PickleRick</dc:creator>
      <dc:date>2022-04-25T16:34:22Z</dc:date>
    </item>
  </channel>
</rss>

