<?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: Why is timechart returning null results if eval returns a value less than 1? in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/Why-is-timechart-returning-null-results-if-eval-returns-a-value/m-p/227492#M67186</link>
    <description>&lt;P&gt;Thank you ... that didn't quite work, but you pointed me in the right direction ...&lt;/P&gt;

&lt;P&gt;earliest=-3d latest=-1d sourcetype=foo | eval number=tonumber(value) | timechart span=1h avg(number) as myValue by host&lt;/P&gt;</description>
    <pubDate>Mon, 16 Nov 2015 15:31:25 GMT</pubDate>
    <dc:creator>pkeller</dc:creator>
    <dc:date>2015-11-16T15:31:25Z</dc:date>
    <item>
      <title>Why is timechart returning null results if eval returns a value less than 1?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Why-is-timechart-returning-null-results-if-eval-returns-a-value/m-p/227489#M67183</link>
      <description>&lt;P&gt;I'm finding that timechart is returning null results if my number is less than 1.&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;earliest=-3d latest=-1d sourcetype=foo | timechart span=1h avg(value) as myValue by host
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;If the overall average of &lt;STRONG&gt;value&lt;/STRONG&gt; is less than one ... ie: .2 or .7 etc ... I get a null result in &lt;STRONG&gt;myValue&lt;/STRONG&gt;&lt;/P&gt;

&lt;P&gt;This works fine for numbers 1 or greater.&lt;/P&gt;

&lt;P&gt;I've tried using &lt;CODE&gt;round&lt;/CODE&gt;, &lt;CODE&gt;exact&lt;/CODE&gt;, and  &lt;CODE&gt;eval(avg(value)*10)&lt;/CODE&gt; ... I still get null results. &lt;/P&gt;</description>
      <pubDate>Fri, 13 Nov 2015 20:36:07 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Why-is-timechart-returning-null-results-if-eval-returns-a-value/m-p/227489#M67183</guid>
      <dc:creator>pkeller</dc:creator>
      <dc:date>2015-11-13T20:36:07Z</dc:date>
    </item>
    <item>
      <title>Re: Why is timechart returning null results if eval returns a value less than 1?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Why-is-timechart-returning-null-results-if-eval-returns-a-value/m-p/227490#M67184</link>
      <description>&lt;P&gt;Try this:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt; earliest=-3d latest=-1d sourcetype=foo | timechart span=1h avg(tonumber(value)) as myValue by host
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Fri, 13 Nov 2015 20:49:26 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Why-is-timechart-returning-null-results-if-eval-returns-a-value/m-p/227490#M67184</guid>
      <dc:creator>woodcock</dc:creator>
      <dc:date>2015-11-13T20:49:26Z</dc:date>
    </item>
    <item>
      <title>Re: Why is timechart returning null results if eval returns a value less than 1?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Why-is-timechart-returning-null-results-if-eval-returns-a-value/m-p/227491#M67185</link>
      <description>&lt;P&gt;never mind ... If I change the provided value to 0.2, 0.7 etc ... this works.&lt;/P&gt;</description>
      <pubDate>Fri, 13 Nov 2015 20:50:48 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Why-is-timechart-returning-null-results-if-eval-returns-a-value/m-p/227491#M67185</guid>
      <dc:creator>pkeller</dc:creator>
      <dc:date>2015-11-13T20:50:48Z</dc:date>
    </item>
    <item>
      <title>Re: Why is timechart returning null results if eval returns a value less than 1?</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Why-is-timechart-returning-null-results-if-eval-returns-a-value/m-p/227492#M67186</link>
      <description>&lt;P&gt;Thank you ... that didn't quite work, but you pointed me in the right direction ...&lt;/P&gt;

&lt;P&gt;earliest=-3d latest=-1d sourcetype=foo | eval number=tonumber(value) | timechart span=1h avg(number) as myValue by host&lt;/P&gt;</description>
      <pubDate>Mon, 16 Nov 2015 15:31:25 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Why-is-timechart-returning-null-results-if-eval-returns-a-value/m-p/227492#M67186</guid>
      <dc:creator>pkeller</dc:creator>
      <dc:date>2015-11-16T15:31:25Z</dc:date>
    </item>
  </channel>
</rss>

