<?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 query filtering on lookup table csv in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/Splunk-query-filtering-on-lookup-table-csv/m-p/155622#M43796</link>
    <description>&lt;P&gt;me too, no results found &lt;/P&gt;</description>
    <pubDate>Wed, 24 Dec 2014 13:17:24 GMT</pubDate>
    <dc:creator>Akili</dc:creator>
    <dc:date>2014-12-24T13:17:24Z</dc:date>
    <item>
      <title>Splunk query filtering on lookup table csv</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Splunk-query-filtering-on-lookup-table-csv/m-p/155619#M43793</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;

&lt;P&gt;I have a query which shows me whether malicious sites have been accessed per client ip:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;"Potentially Unwanted Software" OR "Gambling" OR "Suspicious" OR "Scam/Questionable/Illegal" OR "Proxy Avoidance" | stats count by src_ip | sort count desc
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;I also to have those categories in a lookup table:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;Potentially Unwanted Software
Gambling
Suspicious
Scam/Questionable/Illegal
Proxy Avoidance"
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;I would like to have a query like this:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;lookup malicious_sites.csv | search * | stats count by src_ip | sort count desc
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Somehow it is not working, can you guys help me out what I'm doing wrong?&lt;/P&gt;

&lt;P&gt;V&lt;/P&gt;</description>
      <pubDate>Wed, 08 Oct 2014 12:33:31 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Splunk-query-filtering-on-lookup-table-csv/m-p/155619#M43793</guid>
      <dc:creator>vfm</dc:creator>
      <dc:date>2014-10-08T12:33:31Z</dc:date>
    </item>
    <item>
      <title>Re: Splunk query filtering on lookup table csv</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Splunk-query-filtering-on-lookup-table-csv/m-p/155620#M43794</link>
      <description>&lt;P&gt;lookup doesn't work like that. You should read the docs on the lookup command and the inputlookup command.&lt;/P&gt;

&lt;P&gt;What you want is probably something like this (assuming your field for this is called "category" in both the lookup and your events):&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;[inputlookup malicious_sites.csv | fields category] | stats count by src_ip | sort - count
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Wed, 08 Oct 2014 12:40:03 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Splunk-query-filtering-on-lookup-table-csv/m-p/155620#M43794</guid>
      <dc:creator>Ayn</dc:creator>
      <dc:date>2014-10-08T12:40:03Z</dc:date>
    </item>
    <item>
      <title>Re: Splunk query filtering on lookup table csv</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Splunk-query-filtering-on-lookup-table-csv/m-p/155621#M43795</link>
      <description>&lt;P&gt;Hello Ayn,&lt;/P&gt;

&lt;P&gt;thanks for you response.&lt;BR /&gt;
I tried your query, because it looked exactly like what I wanted. And yes, in both my lookup and the events the field is category&lt;BR /&gt;
However it returns no results, whereas when I put the categories in my query, I do get results.&lt;/P&gt;

&lt;P&gt;This happens also when I try examples I find in the documentation. Somehow there is still something incorrect.&lt;/P&gt;

&lt;P&gt;Regards,&lt;BR /&gt;
V&lt;/P&gt;</description>
      <pubDate>Wed, 08 Oct 2014 13:29:51 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Splunk-query-filtering-on-lookup-table-csv/m-p/155621#M43795</guid>
      <dc:creator>vfm</dc:creator>
      <dc:date>2014-10-08T13:29:51Z</dc:date>
    </item>
    <item>
      <title>Re: Splunk query filtering on lookup table csv</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Splunk-query-filtering-on-lookup-table-csv/m-p/155622#M43796</link>
      <description>&lt;P&gt;me too, no results found &lt;/P&gt;</description>
      <pubDate>Wed, 24 Dec 2014 13:17:24 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Splunk-query-filtering-on-lookup-table-csv/m-p/155622#M43796</guid>
      <dc:creator>Akili</dc:creator>
      <dc:date>2014-12-24T13:17:24Z</dc:date>
    </item>
  </channel>
</rss>

