<?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: Comparing with NULL in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/Comparing-with-NULL/m-p/521389#M146927</link>
    <description>&lt;P&gt;soo, i thought to test this with integer and string..&lt;/P&gt;&lt;P&gt;| makeresults&lt;BR /&gt;| eval N="3"&lt;BR /&gt;| eval i1=if(N==3, "N", "Y")&lt;BR /&gt;| eval i2=if(N != "3", "N", "Y")&lt;/P&gt;&lt;P&gt;i1=N&amp;nbsp; and i2=Y&amp;nbsp;&lt;/P&gt;&lt;P&gt;| makeresults&lt;BR /&gt;| eval N=3&lt;BR /&gt;| eval i1=if(N==3, "N", "Y")&lt;BR /&gt;| eval i2=if(N != "3", "N", "Y")&amp;nbsp;&lt;/P&gt;&lt;P&gt;also produced the above result.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;(PS - i have given around 350+ karma points so far, received badge for that,.. maybe you also should start "Learn, Give Back, Have Fun")&lt;/P&gt;</description>
    <pubDate>Fri, 25 Sep 2020 01:44:38 GMT</pubDate>
    <dc:creator>inventsekar</dc:creator>
    <dc:date>2020-09-25T01:44:38Z</dc:date>
    <item>
      <title>Comparing with NULL</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Comparing-with-NULL/m-p/521387#M146926</link>
      <description>&lt;P&gt;Do I understand correctly that NULL is neither equal (==) nor not equal (!=) to any value?&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;I know about &lt;FONT face="andale mono,times"&gt;isnull()&lt;/FONT&gt;&amp;nbsp;function, but was under (apparently wrong) impression that NULL &lt;STRONG&gt;is&lt;/STRONG&gt;&amp;nbsp; &lt;EM&gt;not equal&lt;/EM&gt; to everything else.&lt;/P&gt;&lt;P&gt;Illustration:&lt;/P&gt;&lt;LI-CODE lang="c"&gt;| makeresults
| eval N=null
| eval i1=if(isnull(N), "N", "Y")
| eval i2=if(N != "Y", "N", "Y")&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;U&gt;Result&lt;/U&gt;:&lt;/P&gt;&lt;TABLE border="1" width="120px"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD width="79px"&gt;&lt;STRONG&gt;i1&lt;/STRONG&gt;&lt;/TD&gt;&lt;TD width="40px"&gt;&lt;STRONG&gt;i2&lt;/STRONG&gt;&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD width="79px"&gt;N&lt;/TD&gt;&lt;TD width="40px"&gt;Y&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Is it fully documented?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 25 Sep 2020 01:24:27 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Comparing-with-NULL/m-p/521387#M146926</guid>
      <dc:creator>pm771</dc:creator>
      <dc:date>2020-09-25T01:24:27Z</dc:date>
    </item>
    <item>
      <title>Re: Comparing with NULL</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Comparing-with-NULL/m-p/521389#M146927</link>
      <description>&lt;P&gt;soo, i thought to test this with integer and string..&lt;/P&gt;&lt;P&gt;| makeresults&lt;BR /&gt;| eval N="3"&lt;BR /&gt;| eval i1=if(N==3, "N", "Y")&lt;BR /&gt;| eval i2=if(N != "3", "N", "Y")&lt;/P&gt;&lt;P&gt;i1=N&amp;nbsp; and i2=Y&amp;nbsp;&lt;/P&gt;&lt;P&gt;| makeresults&lt;BR /&gt;| eval N=3&lt;BR /&gt;| eval i1=if(N==3, "N", "Y")&lt;BR /&gt;| eval i2=if(N != "3", "N", "Y")&amp;nbsp;&lt;/P&gt;&lt;P&gt;also produced the above result.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;(PS - i have given around 350+ karma points so far, received badge for that,.. maybe you also should start "Learn, Give Back, Have Fun")&lt;/P&gt;</description>
      <pubDate>Fri, 25 Sep 2020 01:44:38 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Comparing-with-NULL/m-p/521389#M146927</guid>
      <dc:creator>inventsekar</dc:creator>
      <dc:date>2020-09-25T01:44:38Z</dc:date>
    </item>
    <item>
      <title>Re: Comparing with NULL</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Comparing-with-NULL/m-p/521391#M146928</link>
      <description>&lt;P&gt;What I meant was:&lt;/P&gt;&lt;LI-CODE lang="c"&gt;| makeresults
| eval i1=if(null==null, "true", "false")
| eval i2=if(null!=null, "true", "false")&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;The return will be &lt;STRONG&gt;&lt;FONT color="#339966"&gt;false&lt;/FONT&gt;&lt;/STRONG&gt; and &lt;FONT color="#339966"&gt;&lt;STRONG&gt;false&lt;/STRONG&gt;&lt;/FONT&gt;.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 25 Sep 2020 01:54:12 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Comparing-with-NULL/m-p/521391#M146928</guid>
      <dc:creator>pm771</dc:creator>
      <dc:date>2020-09-25T01:54:12Z</dc:date>
    </item>
  </channel>
</rss>

