<?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: How to calculate daily values from sum values in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/How-to-calculate-daily-values-from-sum-values/m-p/230981#M68515</link>
    <description>&lt;P&gt;Try to add:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt; ....
| delta A as A
| delta B AS B
| delta C AS C
| delta D AS D
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;To compare another span you can add the parameter p=&lt;EM&gt;n&lt;/EM&gt;&lt;BR /&gt;
See the docs here: &lt;A href="http://docs.splunk.com/Documentation/Splunk/6.3.1/SearchReference/Delta"&gt;http://docs.splunk.com/Documentation/Splunk/6.3.1/SearchReference/Delta&lt;/A&gt;&lt;/P&gt;</description>
    <pubDate>Tue, 10 Nov 2015 15:16:59 GMT</pubDate>
    <dc:creator>HeinzWaescher</dc:creator>
    <dc:date>2015-11-10T15:16:59Z</dc:date>
    <item>
      <title>How to calculate daily values from sum values</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-calculate-daily-values-from-sum-values/m-p/230980#M68514</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;

&lt;P&gt;I have values that are a total sum of all data processed. I need to calculate the daily values from the daily sums.&lt;/P&gt;

&lt;P&gt;Running the following search:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;source=... | timechart span=1d eval(round(latest(USED_SPACE)/1024/1024)) as SpaceTB by Media
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;produces results like:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;                    A       B       C       D
2015-11-06      70.85   298.18  8.76    2.44
2015-11-07      71.28   298.78  8.78    2.44
2015-11-08      71.34   299.38  8.78    2.44
2015-11-09      71.36   299.43  8.78    2.50
..
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;I need a table that calculates the amount of data that was processed each day. That means to subtract the current value from the value of the previous day for each day (or other SPAN interval).&lt;/P&gt;

&lt;P&gt;Results should look like&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;                    A       B       C       D
2015-11-06          
2015-11-07      0.43        0.6 0.02    0
2015-11-08      0.06        0.6 0       0
2015-11-09      0.02        0.05    0       0.06
..
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Any suggestions?&lt;BR /&gt;
Thank you&lt;/P&gt;</description>
      <pubDate>Tue, 10 Nov 2015 14:35:54 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-calculate-daily-values-from-sum-values/m-p/230980#M68514</guid>
      <dc:creator>ManfredGrill</dc:creator>
      <dc:date>2015-11-10T14:35:54Z</dc:date>
    </item>
    <item>
      <title>Re: How to calculate daily values from sum values</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-calculate-daily-values-from-sum-values/m-p/230981#M68515</link>
      <description>&lt;P&gt;Try to add:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt; ....
| delta A as A
| delta B AS B
| delta C AS C
| delta D AS D
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;To compare another span you can add the parameter p=&lt;EM&gt;n&lt;/EM&gt;&lt;BR /&gt;
See the docs here: &lt;A href="http://docs.splunk.com/Documentation/Splunk/6.3.1/SearchReference/Delta"&gt;http://docs.splunk.com/Documentation/Splunk/6.3.1/SearchReference/Delta&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 10 Nov 2015 15:16:59 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-calculate-daily-values-from-sum-values/m-p/230981#M68515</guid>
      <dc:creator>HeinzWaescher</dc:creator>
      <dc:date>2015-11-10T15:16:59Z</dc:date>
    </item>
    <item>
      <title>Re: How to calculate daily values from sum values</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-calculate-daily-values-from-sum-values/m-p/230982#M68516</link>
      <description>&lt;P&gt;Hi Heinz,&lt;/P&gt;

&lt;P&gt;This works just great. &lt;BR /&gt;
Automatic creation of the new columns would be nice, but I can easily use this solution.&lt;/P&gt;

&lt;P&gt;Thank you.&lt;BR /&gt;
Manfred&lt;/P&gt;</description>
      <pubDate>Tue, 10 Nov 2015 15:40:20 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-calculate-daily-values-from-sum-values/m-p/230982#M68516</guid>
      <dc:creator>ManfredGrill</dc:creator>
      <dc:date>2015-11-10T15:40:20Z</dc:date>
    </item>
    <item>
      <title>Re: How to calculate daily values from sum values</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-calculate-daily-values-from-sum-values/m-p/230983#M68517</link>
      <description>&lt;P&gt;When the numbers are always growing over time, this could be an option as well to have automatic column creation&lt;/P&gt;

&lt;P&gt;x is the wildcard here, i don't know why the star is ignored in the comments....&lt;/P&gt;

&lt;P&gt;....&lt;BR /&gt;
| streamstats range(x) window=2&lt;BR /&gt;
| fields+ _time, rangex&lt;/P&gt;</description>
      <pubDate>Tue, 10 Nov 2015 15:47:19 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-calculate-daily-values-from-sum-values/m-p/230983#M68517</guid>
      <dc:creator>HeinzWaescher</dc:creator>
      <dc:date>2015-11-10T15:47:19Z</dc:date>
    </item>
  </channel>
</rss>

