<?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: table lookup issues in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/table-lookup-issues/m-p/301992#M90927</link>
    <description>&lt;P&gt;I have another question .. do i have to update my csv file every time I get a new error or is there any other way that can also automatically do this . Just asking out of curiosity.&lt;/P&gt;</description>
    <pubDate>Thu, 18 May 2017 07:11:45 GMT</pubDate>
    <dc:creator>loveforsplunk</dc:creator>
    <dc:date>2017-05-18T07:11:45Z</dc:date>
    <item>
      <title>table lookup issues</title>
      <link>https://community.splunk.com/t5/Splunk-Search/table-lookup-issues/m-p/301988#M90923</link>
      <description>&lt;P&gt;I have a lookup table named lookupfile.csv&lt;BR /&gt;
My file looks like this:&lt;BR /&gt;
col1,col2,col3,col4&lt;BR /&gt;
100,300,500,yes&lt;BR /&gt;
200,400,600,yes1&lt;BR /&gt;
300,100,500,yes3&lt;/P&gt;

&lt;P&gt;My search is : &lt;BR /&gt;
basesearch | lookup mylookup col1 , col2 , col3 OUTPUT col4 | stats count by col1, col2, col3, col4&lt;/P&gt;

&lt;P&gt;For each event where all the input values matches, there will be a resulting field, col4, available for that event.&lt;BR /&gt;
So if I have field1=100 AND field2=300 AND field3=500 then I will get back col4=yes or yes1 or yes2 based on the combination.&lt;/P&gt;

&lt;P&gt;Now , suppose splunk gets a new combination for the base search whose details are not listed in the lookup file. Can I get the combination in statistics tab keeping the col4 field as blank ?&lt;/P&gt;</description>
      <pubDate>Thu, 18 May 2017 05:47:52 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/table-lookup-issues/m-p/301988#M90923</guid>
      <dc:creator>loveforsplunk</dc:creator>
      <dc:date>2017-05-18T05:47:52Z</dc:date>
    </item>
    <item>
      <title>Re: table lookup issues</title>
      <link>https://community.splunk.com/t5/Splunk-Search/table-lookup-issues/m-p/301989#M90924</link>
      <description>&lt;P&gt;Before the stats command add a fillnull for field col4 -&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;basesearch | lookup mylookup col1 , col2 , col3 OUTPUT col4 | fillnull value="" col4 | stats count by col1, col2, col3, col4
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;I would suggest adding a character and not a blank space to make the output easier to read -&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;| fillnull value="-" col4 
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Thu, 18 May 2017 06:01:11 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/table-lookup-issues/m-p/301989#M90924</guid>
      <dc:creator>dineshraj9</dc:creator>
      <dc:date>2017-05-18T06:01:11Z</dc:date>
    </item>
    <item>
      <title>Re: table lookup issues</title>
      <link>https://community.splunk.com/t5/Splunk-Search/table-lookup-issues/m-p/301990#M90925</link>
      <description>&lt;P&gt;Ahhh.. Thank You! I was doing the same thing of adding fillnull command but my mistake was I was adding it at the end of the search string. Thanks buddy!&lt;/P&gt;</description>
      <pubDate>Thu, 18 May 2017 06:56:05 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/table-lookup-issues/m-p/301990#M90925</guid>
      <dc:creator>loveforsplunk</dc:creator>
      <dc:date>2017-05-18T06:56:05Z</dc:date>
    </item>
    <item>
      <title>Re: table lookup issues</title>
      <link>https://community.splunk.com/t5/Splunk-Search/table-lookup-issues/m-p/301991#M90926</link>
      <description>&lt;P&gt;Sure.. no problem &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 18 May 2017 06:58:29 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/table-lookup-issues/m-p/301991#M90926</guid>
      <dc:creator>dineshraj9</dc:creator>
      <dc:date>2017-05-18T06:58:29Z</dc:date>
    </item>
    <item>
      <title>Re: table lookup issues</title>
      <link>https://community.splunk.com/t5/Splunk-Search/table-lookup-issues/m-p/301992#M90927</link>
      <description>&lt;P&gt;I have another question .. do i have to update my csv file every time I get a new error or is there any other way that can also automatically do this . Just asking out of curiosity.&lt;/P&gt;</description>
      <pubDate>Thu, 18 May 2017 07:11:45 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/table-lookup-issues/m-p/301992#M90927</guid>
      <dc:creator>loveforsplunk</dc:creator>
      <dc:date>2017-05-18T07:11:45Z</dc:date>
    </item>
    <item>
      <title>Re: table lookup issues</title>
      <link>https://community.splunk.com/t5/Splunk-Search/table-lookup-issues/m-p/301993#M90928</link>
      <description>&lt;P&gt;If you can form a query to identify new error and populate required fields, you can have another search running to update your lookup file with these fields using outputlookup command.&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;basesearch | lookup mylookup col1 , col2 , col3 OUTPUT col4 | search NOT col4=*
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;This will give you where there are no matches in the lookup and the fields that may have to be updated.&lt;/P&gt;</description>
      <pubDate>Thu, 18 May 2017 07:15:40 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/table-lookup-issues/m-p/301993#M90928</guid>
      <dc:creator>dineshraj9</dc:creator>
      <dc:date>2017-05-18T07:15:40Z</dc:date>
    </item>
    <item>
      <title>Re: table lookup issues</title>
      <link>https://community.splunk.com/t5/Splunk-Search/table-lookup-issues/m-p/301994#M90929</link>
      <description>&lt;P&gt;Thank You!!&lt;/P&gt;</description>
      <pubDate>Sun, 21 May 2017 04:48:16 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/table-lookup-issues/m-p/301994#M90929</guid>
      <dc:creator>loveforsplunk</dc:creator>
      <dc:date>2017-05-21T04:48:16Z</dc:date>
    </item>
  </channel>
</rss>

