<?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: Fillnull not working with chart in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/Fillnull-not-working-with-chart/m-p/189307#M54547</link>
    <description>&lt;P&gt;In your test for "isnotnull", you are saying "if subsystem has any value, replace it with 'not provided'" - I don't think that it is odd.&lt;/P&gt;

&lt;P&gt;Yes, an empty string is technically not a null. Try this&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;index=myIndex 
 | eval subsystem=if(subsystem=="","Not Provided",subsystem)
 | chart count(ticket) by subsystem
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Oops, I see that you figured this out in another answer...&lt;/P&gt;</description>
    <pubDate>Fri, 15 May 2015 18:57:55 GMT</pubDate>
    <dc:creator>lguinn2</dc:creator>
    <dc:date>2015-05-15T18:57:55Z</dc:date>
    <item>
      <title>Fillnull not working with chart</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Fillnull-not-working-with-chart/m-p/189301#M54541</link>
      <description>&lt;P&gt;I'm trying to create a simple chart of the number of tickets for a specified subsystem.  However the subsystem field is not always provided.  Currently, there is a "slice" in my pie chart for tickets with no subsystem, but it has no label (because the subsystem is empty).  The search I'm using is &lt;CODE&gt;index=myIndex | fillnull value="Not Provided" subsystem | chart count(ticket) by subsystem&lt;/CODE&gt;.  I have tried moving the fillnull to after the chart command and I have tried value=NONE but no luck.  Please help&lt;/P&gt;</description>
      <pubDate>Fri, 15 May 2015 15:13:42 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Fillnull-not-working-with-chart/m-p/189301#M54541</guid>
      <dc:creator>lyndac</dc:creator>
      <dc:date>2015-05-15T15:13:42Z</dc:date>
    </item>
    <item>
      <title>Re: Fillnull not working with chart</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Fillnull-not-working-with-chart/m-p/189302#M54542</link>
      <description>&lt;P&gt;The problem is this: when charts counts by subsystem, events without a subsystem are not included. Try this instead:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;index=myIndex 
| eval subsystem=if(isnull(subsystem),"Not Provided",subsystem)
| chart count(ticket) by subsystem
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Fri, 15 May 2015 16:07:48 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Fillnull-not-working-with-chart/m-p/189302#M54542</guid>
      <dc:creator>lguinn2</dc:creator>
      <dc:date>2015-05-15T16:07:48Z</dc:date>
    </item>
    <item>
      <title>Re: Fillnull not working with chart</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Fillnull-not-working-with-chart/m-p/189303#M54543</link>
      <description>&lt;P&gt;Instead of &lt;STRONG&gt;fillnull&lt;/STRONG&gt;, you could use this query:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;index=myIndex| chart count(ticket) by subsystem|where subsystem != " "
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Fri, 15 May 2015 16:08:18 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Fillnull-not-working-with-chart/m-p/189303#M54543</guid>
      <dc:creator>stephanefotso</dc:creator>
      <dc:date>2015-05-15T16:08:18Z</dc:date>
    </item>
    <item>
      <title>Re: Fillnull not working with chart</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Fillnull-not-working-with-chart/m-p/189304#M54544</link>
      <description>&lt;P&gt;if I change the where clause to |where subsystem != "", this works by excluding all the null subsystems.  I'd like to see the count of null subsystems, but I'd like there to be a label that says "Not Provided".&lt;/P&gt;</description>
      <pubDate>Fri, 15 May 2015 18:26:46 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Fillnull-not-working-with-chart/m-p/189304#M54544</guid>
      <dc:creator>lyndac</dc:creator>
      <dc:date>2015-05-15T18:26:46Z</dc:date>
    </item>
    <item>
      <title>Re: Fillnull not working with chart</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Fillnull-not-working-with-chart/m-p/189305#M54545</link>
      <description>&lt;P&gt;Actually, I see a count of subsystems that have no value...it shows up as a slice of the pie with no label.  I tried this solution and it didn't change anything.  &lt;/P&gt;

&lt;P&gt;Oddly, I used &lt;CODE&gt;|eval subsystem=if (isnotnull(subsystem), "Not Provided", subsystem)&lt;/CODE&gt; and it changed ALL the subsystem values to "Not Provided".  &lt;/P&gt;

&lt;P&gt;Does splunk treat an empty string "" differently than a null value?&lt;/P&gt;

&lt;P&gt;BTW -- this data was read in from a csv file where the data and looks like ,"", in the raw data.&lt;/P&gt;</description>
      <pubDate>Fri, 15 May 2015 18:30:33 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Fillnull-not-working-with-chart/m-p/189305#M54545</guid>
      <dc:creator>lyndac</dc:creator>
      <dc:date>2015-05-15T18:30:33Z</dc:date>
    </item>
    <item>
      <title>Re: Fillnull not working with chart</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Fillnull-not-working-with-chart/m-p/189306#M54546</link>
      <description>&lt;P&gt;This works:&lt;/P&gt;

&lt;P&gt;index=myIndex &lt;BR /&gt;
|eval subsystem=if (subsystem == "", "Not Provided", subsystem)&lt;BR /&gt;
| chart count(ticket) by subsystem&lt;/P&gt;</description>
      <pubDate>Fri, 15 May 2015 18:39:23 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Fillnull-not-working-with-chart/m-p/189306#M54546</guid>
      <dc:creator>lyndac</dc:creator>
      <dc:date>2015-05-15T18:39:23Z</dc:date>
    </item>
    <item>
      <title>Re: Fillnull not working with chart</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Fillnull-not-working-with-chart/m-p/189307#M54547</link>
      <description>&lt;P&gt;In your test for "isnotnull", you are saying "if subsystem has any value, replace it with 'not provided'" - I don't think that it is odd.&lt;/P&gt;

&lt;P&gt;Yes, an empty string is technically not a null. Try this&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;index=myIndex 
 | eval subsystem=if(subsystem=="","Not Provided",subsystem)
 | chart count(ticket) by subsystem
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Oops, I see that you figured this out in another answer...&lt;/P&gt;</description>
      <pubDate>Fri, 15 May 2015 18:57:55 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Fillnull-not-working-with-chart/m-p/189307#M54547</guid>
      <dc:creator>lguinn2</dc:creator>
      <dc:date>2015-05-15T18:57:55Z</dc:date>
    </item>
    <item>
      <title>Re: Fillnull not working with chart</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Fillnull-not-working-with-chart/m-p/189308#M54548</link>
      <description>&lt;P&gt;Hi lyndac&lt;/P&gt;

&lt;P&gt;I think that you must simply retry like this :&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;index=myIndex | fillnull value=NONE subsystem | chart count(ticket) by subsystem
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Look at this example it works well&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;sourcetype=access_* |fillnull value=NONE categoryId |chart count(action) as c by categoryId
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;And the result&lt;/P&gt;

&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="![![![alt text][1]][1]][1]"&gt;&lt;img src="https://community.splunk.com/t5/image/serverpage/image-id/352i9811A6CDC5AC0F08/image-size/large?v=v2&amp;amp;px=999" role="button" title="![![![alt text][1]][1]][1]" alt="![![![alt text][1]][1]][1]" /&gt;&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 15 May 2015 22:15:27 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Fillnull-not-working-with-chart/m-p/189308#M54548</guid>
      <dc:creator>chimell</dc:creator>
      <dc:date>2015-05-15T22:15:27Z</dc:date>
    </item>
  </channel>
</rss>

