<?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: I need to fill missing values in a search as NULL in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/I-need-to-fill-missing-values-in-a-search-as-NULL/m-p/283359#M190635</link>
    <description>&lt;P&gt;I've picked up that old habit of answering questions the moment I get the "expert" notification from Splunk,  but I do have that haunting feeling as I type, that someone else might be answering simultaneously.   omg type faster!&lt;/P&gt;</description>
    <pubDate>Tue, 05 Apr 2016 16:22:54 GMT</pubDate>
    <dc:creator>sideview</dc:creator>
    <dc:date>2016-04-05T16:22:54Z</dc:date>
    <item>
      <title>I need to fill missing values in a search as NULL</title>
      <link>https://community.splunk.com/t5/Splunk-Search/I-need-to-fill-missing-values-in-a-search-as-NULL/m-p/283353#M190629</link>
      <description>&lt;P&gt;I need to fill missing values from search items as NULL (not the string, but actual NULL values)&lt;/P&gt;

&lt;P&gt;I see options to check if the values is NULL (isnull) or even fill NULL values with a string (fillnull). But what I need is to write the value to be NULL.&lt;/P&gt;

&lt;P&gt;I searched but could not get an answer.&lt;/P&gt;

&lt;P&gt;Thanks for all the help in this matter.&lt;BR /&gt;
Abhi&lt;/P&gt;</description>
      <pubDate>Mon, 04 Apr 2016 23:54:49 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/I-need-to-fill-missing-values-in-a-search-as-NULL/m-p/283353#M190629</guid>
      <dc:creator>abhijitp</dc:creator>
      <dc:date>2016-04-04T23:54:49Z</dc:date>
    </item>
    <item>
      <title>Re: I need to fill missing values in a search as NULL</title>
      <link>https://community.splunk.com/t5/Splunk-Search/I-need-to-fill-missing-values-in-a-search-as-NULL/m-p/283354#M190630</link>
      <description>&lt;P&gt;it's just  &lt;CODE&gt;null()&lt;/CODE&gt;&lt;/P&gt;

&lt;P&gt;So you can do things like &lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;| eval foo=if(sky="blue",foo,null())   
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;that would conditionally erase the field "foo" from any rows that claim the sky is not blue. &lt;/P&gt;

&lt;P&gt;Extra reading:  A fair number of examples out there use "null"  as though it was a reserved keyword in the eval command but it is not.  those examples just happen to work because there is generally not a field called "null",  and eval allows you to name any field at all.   thus specifying null is the same as nonexistentField, and is generally null valued... &lt;/P&gt;</description>
      <pubDate>Mon, 04 Apr 2016 23:59:38 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/I-need-to-fill-missing-values-in-a-search-as-NULL/m-p/283354#M190630</guid>
      <dc:creator>sideview</dc:creator>
      <dc:date>2016-04-04T23:59:38Z</dc:date>
    </item>
    <item>
      <title>Re: I need to fill missing values in a search as NULL</title>
      <link>https://community.splunk.com/t5/Splunk-Search/I-need-to-fill-missing-values-in-a-search-as-NULL/m-p/283355#M190631</link>
      <description>&lt;P&gt;Thanks. Let me try this out.&lt;/P&gt;</description>
      <pubDate>Tue, 05 Apr 2016 00:01:47 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/I-need-to-fill-missing-values-in-a-search-as-NULL/m-p/283355#M190631</guid>
      <dc:creator>abhijitp</dc:creator>
      <dc:date>2016-04-05T00:01:47Z</dc:date>
    </item>
    <item>
      <title>Re: I need to fill missing values in a search as NULL</title>
      <link>https://community.splunk.com/t5/Splunk-Search/I-need-to-fill-missing-values-in-a-search-as-NULL/m-p/283356#M190632</link>
      <description>&lt;P&gt;Hi abhijitp,&lt;/P&gt;

&lt;P&gt;did you look at the &lt;CODE&gt;eval&lt;/CODE&gt; function &lt;CODE&gt;null()&lt;/CODE&gt; &lt;A href="http://docs.splunk.com/Documentation/Splunk/6.3.3/SearchReference/CommonEvalFunctions"&gt;http://docs.splunk.com/Documentation/Splunk/6.3.3/SearchReference/CommonEvalFunctions&lt;/A&gt; ?&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;null()  
This function takes no arguments and returns NULL. 
The evaluation engine uses NULL to represent "no value"; setting a field to NULL clears its value.
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Hope this helps ...&lt;/P&gt;

&lt;P&gt;cheers, MuS&lt;/P&gt;</description>
      <pubDate>Tue, 05 Apr 2016 00:01:48 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/I-need-to-fill-missing-values-in-a-search-as-NULL/m-p/283356#M190632</guid>
      <dc:creator>MuS</dc:creator>
      <dc:date>2016-04-05T00:01:48Z</dc:date>
    </item>
    <item>
      <title>Re: I need to fill missing values in a search as NULL</title>
      <link>https://community.splunk.com/t5/Splunk-Search/I-need-to-fill-missing-values-in-a-search-as-NULL/m-p/283357#M190633</link>
      <description>&lt;P&gt;Again too slow today &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 05 Apr 2016 00:02:13 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/I-need-to-fill-missing-values-in-a-search-as-NULL/m-p/283357#M190633</guid>
      <dc:creator>MuS</dc:creator>
      <dc:date>2016-04-05T00:02:13Z</dc:date>
    </item>
    <item>
      <title>Re: I need to fill missing values in a search as NULL</title>
      <link>https://community.splunk.com/t5/Splunk-Search/I-need-to-fill-missing-values-in-a-search-as-NULL/m-p/283358#M190634</link>
      <description>&lt;P&gt;I tied @sideview yesterday on an answer and we both had typos but OP selected him.&lt;/P&gt;</description>
      <pubDate>Tue, 05 Apr 2016 12:54:57 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/I-need-to-fill-missing-values-in-a-search-as-NULL/m-p/283358#M190634</guid>
      <dc:creator>woodcock</dc:creator>
      <dc:date>2016-04-05T12:54:57Z</dc:date>
    </item>
    <item>
      <title>Re: I need to fill missing values in a search as NULL</title>
      <link>https://community.splunk.com/t5/Splunk-Search/I-need-to-fill-missing-values-in-a-search-as-NULL/m-p/283359#M190635</link>
      <description>&lt;P&gt;I've picked up that old habit of answering questions the moment I get the "expert" notification from Splunk,  but I do have that haunting feeling as I type, that someone else might be answering simultaneously.   omg type faster!&lt;/P&gt;</description>
      <pubDate>Tue, 05 Apr 2016 16:22:54 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/I-need-to-fill-missing-values-in-a-search-as-NULL/m-p/283359#M190635</guid>
      <dc:creator>sideview</dc:creator>
      <dc:date>2016-04-05T16:22:54Z</dc:date>
    </item>
    <item>
      <title>Re: I need to fill missing values in a search as NULL</title>
      <link>https://community.splunk.com/t5/Splunk-Search/I-need-to-fill-missing-values-in-a-search-as-NULL/m-p/283360#M190636</link>
      <description>&lt;P&gt;Thanks all the help. It worked as I wanted using this&lt;/P&gt;

&lt;P&gt;| eval foo=if(sky="blue",foo,null())  &lt;/P&gt;</description>
      <pubDate>Tue, 05 Apr 2016 17:12:57 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/I-need-to-fill-missing-values-in-a-search-as-NULL/m-p/283360#M190636</guid>
      <dc:creator>abhijitp</dc:creator>
      <dc:date>2016-04-05T17:12:57Z</dc:date>
    </item>
    <item>
      <title>Re: I need to fill missing values in a search as NULL</title>
      <link>https://community.splunk.com/t5/Splunk-Search/I-need-to-fill-missing-values-in-a-search-as-NULL/m-p/283361#M190637</link>
      <description>&lt;P&gt;I really love the camaraderie &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 05 Apr 2016 17:14:43 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/I-need-to-fill-missing-values-in-a-search-as-NULL/m-p/283361#M190637</guid>
      <dc:creator>abhijitp</dc:creator>
      <dc:date>2016-04-05T17:14:43Z</dc:date>
    </item>
    <item>
      <title>Re: I need to fill missing values in a search as NULL</title>
      <link>https://community.splunk.com/t5/Splunk-Search/I-need-to-fill-missing-values-in-a-search-as-NULL/m-p/283362#M190638</link>
      <description>&lt;P&gt;Try this , it resolved my problem.&lt;/P&gt;

&lt;P&gt;&lt;CODE&gt;|fillnull value="#"&lt;/CODE&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 05 Apr 2016 17:34:15 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/I-need-to-fill-missing-values-in-a-search-as-NULL/m-p/283362#M190638</guid>
      <dc:creator>kartik13</dc:creator>
      <dc:date>2016-04-05T17:34:15Z</dc:date>
    </item>
    <item>
      <title>Re: I need to fill missing values in a search as NULL</title>
      <link>https://community.splunk.com/t5/Splunk-Search/I-need-to-fill-missing-values-in-a-search-as-NULL/m-p/283363#M190639</link>
      <description>&lt;P&gt;HeHe, I have no problem at all if an OP selects @sideview 's answer to be the right one over mine, because @sideview will be for sure more right/correct/precise then I am !&lt;/P&gt;

&lt;P&gt;This is also because &lt;CODE&gt;I do not know Splunk ©&lt;/CODE&gt; .... I'm still learning and I have no problem at all to admit that fact &lt;span class="lia-unicode-emoji" title=":winking_face:"&gt;😉&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 08 Apr 2016 12:37:50 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/I-need-to-fill-missing-values-in-a-search-as-NULL/m-p/283363#M190639</guid>
      <dc:creator>MuS</dc:creator>
      <dc:date>2016-04-08T12:37:50Z</dc:date>
    </item>
  </channel>
</rss>

