<?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: Need to compare the contents of a lookup file with search results in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/Need-to-compare-the-contents-of-a-lookup-file-with-search/m-p/553424#M157134</link>
    <description>&lt;P&gt;Try adding the format command to the subsearch.&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;| inputlookup all_identities_prod.csv where NOT [search index=sec ab_id=cvo host=xxx-xxxx* identity="*" | dedup identity | format] 
| table identity&lt;/LI-CODE&gt;</description>
    <pubDate>Fri, 28 May 2021 00:09:27 GMT</pubDate>
    <dc:creator>richgalloway</dc:creator>
    <dc:date>2021-05-28T00:09:27Z</dc:date>
    <item>
      <title>Need to compare the contents of a lookup file with search results</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Need-to-compare-the-contents-of-a-lookup-file-with-search/m-p/553422#M157133</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp;Brand new to splunk here.&amp;nbsp; I've been using it about 1 month.&amp;nbsp; I have a lookup file, all_identities_prod.csv,&lt;SPAN&gt;&amp;nbsp;that has a single column of identities (these look like email addresses) and the column name is 'identity'.&amp;nbsp; What I've been trying to do is to compare the identities in the file with the result of a 30 day search to find identities that are in the lookup file but &lt;EM&gt;not&lt;/EM&gt; in the search results.&amp;nbsp; I've tried this many different ways.&amp;nbsp; Maybe using a lookup file for this isn't the best idea.&amp;nbsp; I don't know.&amp;nbsp; Here's an example of what I've been trying.&amp;nbsp; A subsearch seemed like the best idea.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;| inputlookup all_identities_prod.csv where NOT [search index=sec ab_id=cvo host=xxx-xxxx* identity="*" | dedup identity] | table identity&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;I have to obfuscate the host name understandably.&amp;nbsp; What I get back from this is the full list of the identities in the lookup file.&amp;nbsp; I think the comparison function is where I'm lost.&amp;nbsp; &amp;nbsp;Any ideas?&amp;nbsp; Maybe a better way of doing this altogether?&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Thanks in advance.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 27 May 2021 23:42:56 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Need-to-compare-the-contents-of-a-lookup-file-with-search/m-p/553422#M157133</guid>
      <dc:creator>jcaron9999a</dc:creator>
      <dc:date>2021-05-27T23:42:56Z</dc:date>
    </item>
    <item>
      <title>Re: Need to compare the contents of a lookup file with search results</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Need-to-compare-the-contents-of-a-lookup-file-with-search/m-p/553424#M157134</link>
      <description>&lt;P&gt;Try adding the format command to the subsearch.&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;| inputlookup all_identities_prod.csv where NOT [search index=sec ab_id=cvo host=xxx-xxxx* identity="*" | dedup identity | format] 
| table identity&lt;/LI-CODE&gt;</description>
      <pubDate>Fri, 28 May 2021 00:09:27 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Need-to-compare-the-contents-of-a-lookup-file-with-search/m-p/553424#M157134</guid>
      <dc:creator>richgalloway</dc:creator>
      <dc:date>2021-05-28T00:09:27Z</dc:date>
    </item>
    <item>
      <title>Re: Need to compare the contents of a lookup file with search results</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Need-to-compare-the-contents-of-a-lookup-file-with-search/m-p/553443#M157140</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/234881"&gt;@jcaron9999a&lt;/a&gt;,&lt;/P&gt;&lt;P&gt;let me understand: you want to know the identities from your lookup not present in the search results, is it correct?&lt;/P&gt;&lt;P&gt;If this is your need, please try this:&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;index=sec ab_id=cvo host=xxx-xxxx* identity="*" 
| eval identity=lower(identity)
| stats count BY identity
| append [ 
     | inputlookup all_identities_prod.csv 
     | eval identity=lower(identity), count=0
     | fields identity count
     ]
| stats sum(count) AS total BY identity
| where total=0 &lt;/LI-CODE&gt;&lt;P&gt;Ciao.&lt;/P&gt;&lt;P&gt;Giuseppe&lt;/P&gt;</description>
      <pubDate>Fri, 28 May 2021 06:14:14 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Need-to-compare-the-contents-of-a-lookup-file-with-search/m-p/553443#M157140</guid>
      <dc:creator>gcusello</dc:creator>
      <dc:date>2021-05-28T06:14:14Z</dc:date>
    </item>
    <item>
      <title>Re: Need to compare the contents of a lookup file with search results</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Need-to-compare-the-contents-of-a-lookup-file-with-search/m-p/553599#M157181</link>
      <description>&lt;P&gt;Thanks&amp;nbsp;&lt;SPAN&gt;Giuseppe.&amp;nbsp; Works perfectly.&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 28 May 2021 22:44:01 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Need-to-compare-the-contents-of-a-lookup-file-with-search/m-p/553599#M157181</guid>
      <dc:creator>jcaron9999a</dc:creator>
      <dc:date>2021-05-28T22:44:01Z</dc:date>
    </item>
    <item>
      <title>Re: Need to compare the contents of a lookup file with search results</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Need-to-compare-the-contents-of-a-lookup-file-with-search/m-p/553605#M157183</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/234881"&gt;@jcaron9999a&lt;/a&gt;,&lt;/P&gt;&lt;P&gt;good for you, see next time!&lt;/P&gt;&lt;P&gt;Please accept the answer or the other people of Community.&lt;/P&gt;&lt;P&gt;Ciao and happy splunking.&lt;/P&gt;&lt;P&gt;Giuseppe&lt;/P&gt;&lt;P&gt;P.S.: Karma Points are appreciated by all the contributors &lt;span class="lia-unicode-emoji" title=":winking_face:"&gt;😉&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Sat, 29 May 2021 05:19:21 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Need-to-compare-the-contents-of-a-lookup-file-with-search/m-p/553605#M157183</guid>
      <dc:creator>gcusello</dc:creator>
      <dc:date>2021-05-29T05:19:21Z</dc:date>
    </item>
  </channel>
</rss>

