<?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 do I get the cumulative percentage in Splunk in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/How-do-I-get-the-cumulative-percentage-in-Splunk/m-p/103112#M26663</link>
    <description>&lt;P&gt;The only way I could think of solving this not knowing what your data looks like was to use streamstats and appendcols subsearch.  The following was works, but was scrubbed.&lt;/P&gt;

&lt;P&gt;First I use stats to sum &amp;lt;field&amp;gt; as &amp;lt;count&amp;gt; by &amp;lt;record&amp;gt; , easy part.&lt;BR /&gt;&lt;BR /&gt;
&lt;CODE&gt;&lt;/CODE&gt;&lt;PRE&gt;&lt;CODE&gt;&lt;BR /&gt;
index=myindex sourcetype="mysource" | stats sum(FIELD) as count by record&lt;BR /&gt;
&lt;/CODE&gt;&lt;/PRE&gt;&lt;BR /&gt;
Sample Return:&lt;BR /&gt;
&lt;CODE&gt;&lt;/CODE&gt;&lt;PRE&gt;&lt;CODE&gt;&lt;BR /&gt;
record      count&lt;BR /&gt;
1   Record1     33&lt;BR /&gt;
2   Record2 3&lt;BR /&gt;
3   Record3 2&lt;BR /&gt;
4   Record4 8&lt;BR /&gt;
5   Record5 4&lt;BR /&gt;
6   Record6 28&lt;BR /&gt;
7   Record7 803&lt;BR /&gt;
&lt;/CODE&gt;&lt;/PRE&gt;&lt;BR /&gt;
Next you have to pipe the result into a streamstats command sum &amp;lt;count&amp;gt; as &amp;lt;accumative_count&amp;gt; to find the sum of all pervious values. &lt;BR /&gt;
&lt;CODE&gt;&lt;/CODE&gt;&lt;PRE&gt;&lt;CODE&gt;&lt;BR /&gt;
streamstats sum(count) as accumative_count&lt;BR /&gt;
&lt;/CODE&gt;&lt;/PRE&gt;&lt;BR /&gt;
Sample:&lt;BR /&gt;
&lt;CODE&gt;&lt;/CODE&gt;&lt;PRE&gt;&lt;CODE&gt;&lt;BR /&gt;
    record  count   accumative_count&lt;BR /&gt;
1   Record1 33  33&lt;BR /&gt;
2   Record2 3   36&lt;BR /&gt;
3   Record3 2   38&lt;BR /&gt;
4   Record4 8   46&lt;BR /&gt;
5   Record5 4   50&lt;BR /&gt;
6   Record6 28  78&lt;BR /&gt;
7   Record7 803 881&lt;BR /&gt;
&lt;/CODE&gt;&lt;/PRE&gt;&lt;BR /&gt;
You still need to find total which is easy.&lt;BR /&gt;
&lt;CODE&gt;&lt;/CODE&gt;&lt;PRE&gt;&lt;CODE&gt;&lt;BR /&gt;
index=myindex sourcetype="mysource" | stats sum(FIELD) as total&lt;BR /&gt;
&lt;/CODE&gt;&lt;/PRE&gt;&lt;BR /&gt;
Sample:&lt;BR /&gt;
&lt;CODE&gt;&lt;/CODE&gt;&lt;PRE&gt;&lt;CODE&gt;&lt;BR /&gt;
    total&lt;BR /&gt;
1   881&lt;BR /&gt;
&lt;/CODE&gt;&lt;/PRE&gt;&lt;BR /&gt;
You still need to get the search to result set which is done by appending the total search to your main search by using appendcols.&lt;BR /&gt;
&lt;CODE&gt;&lt;/CODE&gt;&lt;PRE&gt;&lt;CODE&gt;&lt;BR /&gt;
index=myindex sourcetype="mysource" | stats sum(FIELD) as count by record | streamstats sum(count) as accumativ\e_count | appendcols [search index=myindex sourcetype="mysource" | stats sum(FIELD) as total ] | fields  record, count,accumative_count, total&lt;BR /&gt;
&lt;/CODE&gt;&lt;/PRE&gt;&lt;BR /&gt;
Sample:&lt;BR /&gt;
&lt;CODE&gt;&lt;/CODE&gt;&lt;PRE&gt;&lt;CODE&gt;&lt;BR /&gt;
    record  count   accumative_count   total&lt;BR /&gt;
1   Record1 33  33          881&lt;BR /&gt;
2   Record2 3   36&lt;BR /&gt;
3   Record3 2   38&lt;BR /&gt;
4   Record4 8   46&lt;BR /&gt;
5   Record5 4   50&lt;BR /&gt;
6   Record6 28  78&lt;BR /&gt;
7   Record7 803 881&lt;BR /&gt;
&lt;/CODE&gt;&lt;/PRE&gt;&lt;BR /&gt;
Ok, but now total only returns one value in the total column and the rest are null.  This is problem because you can perform math on null fields.  To fix this add the filldown command.&lt;BR /&gt;
&lt;CODE&gt;&lt;/CODE&gt;&lt;PRE&gt;&lt;CODE&gt;&lt;BR /&gt;
index=myindex sourcetype="mysource" | stats sum(FIELD) as count by record | streamstats sum(count) as accumative_count | appendcols [search index=myindex sourcetype="mysource" | stats sum(FIELD) as total ] | filldown total | fields  record, count,accumative_count, total&lt;BR /&gt;
&lt;/CODE&gt;&lt;/PRE&gt;&lt;BR /&gt;
Sample:&lt;BR /&gt;
&lt;CODE&gt;&lt;/CODE&gt;&lt;PRE&gt;&lt;CODE&gt;&lt;BR /&gt;
    record  count   accumative_count   total&lt;BR /&gt;
1   Record1 33  33          881&lt;BR /&gt;
2   Record2 3   36          881&lt;BR /&gt;
3   Record3 2   38          881&lt;BR /&gt;
4   Record4 8   46          881&lt;BR /&gt;
5   Record5 4   50          881&lt;BR /&gt;
6   Record6 28  78          881&lt;BR /&gt;
7   Record7 803 881         881&lt;BR /&gt;
&lt;/CODE&gt;&lt;/PRE&gt;&lt;BR /&gt;
Now we can do our percentage math.&lt;BR /&gt;
&lt;CODE&gt;&lt;/CODE&gt;&lt;PRE&gt;&lt;CODE&gt;&lt;BR /&gt;
eval percentage=((accumative_count/total)*100) &lt;BR /&gt;
&lt;/CODE&gt;&lt;/PRE&gt;&lt;/P&gt;

&lt;P&gt;Let put it all together. &lt;/P&gt;

&lt;P&gt;&lt;CODE&gt;&lt;/CODE&gt;&lt;PRE&gt;&lt;CODE&gt;&lt;BR /&gt;
index="myindex" sourcetype="mysource" | stats sum(FIELD) as count by record | streamstats sum(count) as accumative_count | appendcols [search index=myindex sourcetype="mysource" | stats sum(FIELD) as total ] | filldown total| fields record, count,accumative_count, total | eval percentage=((accumative_count/total)*100) | table record, count, accumative_count, percentage, total&lt;BR /&gt;
&lt;/CODE&gt;&lt;/PRE&gt;&lt;/P&gt;

&lt;P&gt;Final Result Sample:&lt;BR /&gt;
&lt;CODE&gt;&lt;/CODE&gt;&lt;PRE&gt;&lt;CODE&gt;&lt;BR /&gt;
    record  count   accumative_count   percentage  total&lt;BR /&gt;
1   Record1 33  33          3.7457  881&lt;BR /&gt;
2   Record2 3   36          4.0562  881&lt;BR /&gt;
3   Record3 2   38          4.3132  881&lt;BR /&gt;
4   Record4 8   46          5.2213  881&lt;BR /&gt;
5   Record5 4   50          5.6753  881&lt;BR /&gt;
6   Record6 28  78          8.5130  881&lt;BR /&gt;
7   Record7 803 881         100 881&lt;BR /&gt;
&lt;/CODE&gt;&lt;/PRE&gt;&lt;/P&gt;

&lt;P&gt;Hope this helps you and that I escaped all the special chars. Cheers&lt;/P&gt;

&lt;P&gt;&lt;STRONG&gt;Please don't forget to click accept and up this post, if it helps you&lt;/STRONG&gt;.&lt;/P&gt;

&lt;P&gt;Additional reading:&lt;BR /&gt;
&lt;A href="http://docs.splunk.com/Documentation/Splunk/5.0/SearchReference/Streamstats"&gt;Streamstats&lt;/A&gt;&lt;BR /&gt;
&lt;A href="http://docs.splunk.com/Documentation/Splunk/5.0/SearchReference/Filldown"&gt;Filldown&lt;/A&gt;&lt;BR /&gt;
&lt;A href="http://docs.splunk.com/Documentation/Splunk/5.0/SearchReference/Appendcols"&gt;Appendcols&lt;/A&gt;&lt;BR /&gt;
&lt;A href="http://docs.splunk.com/Documentation/Splunk/5.0/Search/Aboutsubsearches"&gt;Howsubsearcheswork&lt;/A&gt;&lt;/P&gt;</description>
    <pubDate>Fri, 26 Oct 2012 00:10:31 GMT</pubDate>
    <dc:creator>bmacias84</dc:creator>
    <dc:date>2012-10-26T00:10:31Z</dc:date>
    <item>
      <title>How do I get the cumulative percentage in Splunk</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-do-I-get-the-cumulative-percentage-in-Splunk/m-p/103110#M26661</link>
      <description>&lt;P&gt;Hello&lt;/P&gt;

&lt;P&gt;I am trying to get a cumulative percentage and have been unsuccessful with it.&lt;/P&gt;

&lt;P&gt;The data is below. so the equation should be something like this&lt;/P&gt;

&lt;P&gt;1st step would be (10/973)*100, 2nd would be ((10+9)/973)*100 3rd would be ((10+9+7)/973)*100 etc.. Any idea on how do I get it? &lt;/P&gt;

&lt;BLOCKQUOTE&gt;
&lt;P&gt;record.affectedCI    count   Total&lt;BR /&gt;
1   WASBC3ST    10  973&lt;BR /&gt;
2   WASDQWY3    9   973&lt;BR /&gt;
3   WASBDH5X    7   973&lt;BR /&gt;
4   WASBDPVY    7   973&lt;BR /&gt;
5   WASBDP2B    6   973&lt;BR /&gt;
6   WASBGLL6    6   973&lt;BR /&gt;
7   WASBN18S    6   973&lt;/P&gt;
&lt;/BLOCKQUOTE&gt;</description>
      <pubDate>Mon, 28 Sep 2020 12:41:42 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-do-I-get-the-cumulative-percentage-in-Splunk/m-p/103110#M26661</guid>
      <dc:creator>theouhuios</dc:creator>
      <dc:date>2020-09-28T12:41:42Z</dc:date>
    </item>
    <item>
      <title>Re: How do I get the cumulative percentage in Splunk</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-do-I-get-the-cumulative-percentage-in-Splunk/m-p/103111#M26662</link>
      <description>&lt;P&gt;I am not sure if that what your _raw data looks like or  if thats your searches output.  Please provide a sample of the _raw or your search.&lt;/P&gt;</description>
      <pubDate>Thu, 25 Oct 2012 23:16:54 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-do-I-get-the-cumulative-percentage-in-Splunk/m-p/103111#M26662</guid>
      <dc:creator>bmacias84</dc:creator>
      <dc:date>2012-10-25T23:16:54Z</dc:date>
    </item>
    <item>
      <title>Re: How do I get the cumulative percentage in Splunk</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-do-I-get-the-cumulative-percentage-in-Splunk/m-p/103112#M26663</link>
      <description>&lt;P&gt;The only way I could think of solving this not knowing what your data looks like was to use streamstats and appendcols subsearch.  The following was works, but was scrubbed.&lt;/P&gt;

&lt;P&gt;First I use stats to sum &amp;lt;field&amp;gt; as &amp;lt;count&amp;gt; by &amp;lt;record&amp;gt; , easy part.&lt;BR /&gt;&lt;BR /&gt;
&lt;CODE&gt;&lt;/CODE&gt;&lt;PRE&gt;&lt;CODE&gt;&lt;BR /&gt;
index=myindex sourcetype="mysource" | stats sum(FIELD) as count by record&lt;BR /&gt;
&lt;/CODE&gt;&lt;/PRE&gt;&lt;BR /&gt;
Sample Return:&lt;BR /&gt;
&lt;CODE&gt;&lt;/CODE&gt;&lt;PRE&gt;&lt;CODE&gt;&lt;BR /&gt;
record      count&lt;BR /&gt;
1   Record1     33&lt;BR /&gt;
2   Record2 3&lt;BR /&gt;
3   Record3 2&lt;BR /&gt;
4   Record4 8&lt;BR /&gt;
5   Record5 4&lt;BR /&gt;
6   Record6 28&lt;BR /&gt;
7   Record7 803&lt;BR /&gt;
&lt;/CODE&gt;&lt;/PRE&gt;&lt;BR /&gt;
Next you have to pipe the result into a streamstats command sum &amp;lt;count&amp;gt; as &amp;lt;accumative_count&amp;gt; to find the sum of all pervious values. &lt;BR /&gt;
&lt;CODE&gt;&lt;/CODE&gt;&lt;PRE&gt;&lt;CODE&gt;&lt;BR /&gt;
streamstats sum(count) as accumative_count&lt;BR /&gt;
&lt;/CODE&gt;&lt;/PRE&gt;&lt;BR /&gt;
Sample:&lt;BR /&gt;
&lt;CODE&gt;&lt;/CODE&gt;&lt;PRE&gt;&lt;CODE&gt;&lt;BR /&gt;
    record  count   accumative_count&lt;BR /&gt;
1   Record1 33  33&lt;BR /&gt;
2   Record2 3   36&lt;BR /&gt;
3   Record3 2   38&lt;BR /&gt;
4   Record4 8   46&lt;BR /&gt;
5   Record5 4   50&lt;BR /&gt;
6   Record6 28  78&lt;BR /&gt;
7   Record7 803 881&lt;BR /&gt;
&lt;/CODE&gt;&lt;/PRE&gt;&lt;BR /&gt;
You still need to find total which is easy.&lt;BR /&gt;
&lt;CODE&gt;&lt;/CODE&gt;&lt;PRE&gt;&lt;CODE&gt;&lt;BR /&gt;
index=myindex sourcetype="mysource" | stats sum(FIELD) as total&lt;BR /&gt;
&lt;/CODE&gt;&lt;/PRE&gt;&lt;BR /&gt;
Sample:&lt;BR /&gt;
&lt;CODE&gt;&lt;/CODE&gt;&lt;PRE&gt;&lt;CODE&gt;&lt;BR /&gt;
    total&lt;BR /&gt;
1   881&lt;BR /&gt;
&lt;/CODE&gt;&lt;/PRE&gt;&lt;BR /&gt;
You still need to get the search to result set which is done by appending the total search to your main search by using appendcols.&lt;BR /&gt;
&lt;CODE&gt;&lt;/CODE&gt;&lt;PRE&gt;&lt;CODE&gt;&lt;BR /&gt;
index=myindex sourcetype="mysource" | stats sum(FIELD) as count by record | streamstats sum(count) as accumativ\e_count | appendcols [search index=myindex sourcetype="mysource" | stats sum(FIELD) as total ] | fields  record, count,accumative_count, total&lt;BR /&gt;
&lt;/CODE&gt;&lt;/PRE&gt;&lt;BR /&gt;
Sample:&lt;BR /&gt;
&lt;CODE&gt;&lt;/CODE&gt;&lt;PRE&gt;&lt;CODE&gt;&lt;BR /&gt;
    record  count   accumative_count   total&lt;BR /&gt;
1   Record1 33  33          881&lt;BR /&gt;
2   Record2 3   36&lt;BR /&gt;
3   Record3 2   38&lt;BR /&gt;
4   Record4 8   46&lt;BR /&gt;
5   Record5 4   50&lt;BR /&gt;
6   Record6 28  78&lt;BR /&gt;
7   Record7 803 881&lt;BR /&gt;
&lt;/CODE&gt;&lt;/PRE&gt;&lt;BR /&gt;
Ok, but now total only returns one value in the total column and the rest are null.  This is problem because you can perform math on null fields.  To fix this add the filldown command.&lt;BR /&gt;
&lt;CODE&gt;&lt;/CODE&gt;&lt;PRE&gt;&lt;CODE&gt;&lt;BR /&gt;
index=myindex sourcetype="mysource" | stats sum(FIELD) as count by record | streamstats sum(count) as accumative_count | appendcols [search index=myindex sourcetype="mysource" | stats sum(FIELD) as total ] | filldown total | fields  record, count,accumative_count, total&lt;BR /&gt;
&lt;/CODE&gt;&lt;/PRE&gt;&lt;BR /&gt;
Sample:&lt;BR /&gt;
&lt;CODE&gt;&lt;/CODE&gt;&lt;PRE&gt;&lt;CODE&gt;&lt;BR /&gt;
    record  count   accumative_count   total&lt;BR /&gt;
1   Record1 33  33          881&lt;BR /&gt;
2   Record2 3   36          881&lt;BR /&gt;
3   Record3 2   38          881&lt;BR /&gt;
4   Record4 8   46          881&lt;BR /&gt;
5   Record5 4   50          881&lt;BR /&gt;
6   Record6 28  78          881&lt;BR /&gt;
7   Record7 803 881         881&lt;BR /&gt;
&lt;/CODE&gt;&lt;/PRE&gt;&lt;BR /&gt;
Now we can do our percentage math.&lt;BR /&gt;
&lt;CODE&gt;&lt;/CODE&gt;&lt;PRE&gt;&lt;CODE&gt;&lt;BR /&gt;
eval percentage=((accumative_count/total)*100) &lt;BR /&gt;
&lt;/CODE&gt;&lt;/PRE&gt;&lt;/P&gt;

&lt;P&gt;Let put it all together. &lt;/P&gt;

&lt;P&gt;&lt;CODE&gt;&lt;/CODE&gt;&lt;PRE&gt;&lt;CODE&gt;&lt;BR /&gt;
index="myindex" sourcetype="mysource" | stats sum(FIELD) as count by record | streamstats sum(count) as accumative_count | appendcols [search index=myindex sourcetype="mysource" | stats sum(FIELD) as total ] | filldown total| fields record, count,accumative_count, total | eval percentage=((accumative_count/total)*100) | table record, count, accumative_count, percentage, total&lt;BR /&gt;
&lt;/CODE&gt;&lt;/PRE&gt;&lt;/P&gt;

&lt;P&gt;Final Result Sample:&lt;BR /&gt;
&lt;CODE&gt;&lt;/CODE&gt;&lt;PRE&gt;&lt;CODE&gt;&lt;BR /&gt;
    record  count   accumative_count   percentage  total&lt;BR /&gt;
1   Record1 33  33          3.7457  881&lt;BR /&gt;
2   Record2 3   36          4.0562  881&lt;BR /&gt;
3   Record3 2   38          4.3132  881&lt;BR /&gt;
4   Record4 8   46          5.2213  881&lt;BR /&gt;
5   Record5 4   50          5.6753  881&lt;BR /&gt;
6   Record6 28  78          8.5130  881&lt;BR /&gt;
7   Record7 803 881         100 881&lt;BR /&gt;
&lt;/CODE&gt;&lt;/PRE&gt;&lt;/P&gt;

&lt;P&gt;Hope this helps you and that I escaped all the special chars. Cheers&lt;/P&gt;

&lt;P&gt;&lt;STRONG&gt;Please don't forget to click accept and up this post, if it helps you&lt;/STRONG&gt;.&lt;/P&gt;

&lt;P&gt;Additional reading:&lt;BR /&gt;
&lt;A href="http://docs.splunk.com/Documentation/Splunk/5.0/SearchReference/Streamstats"&gt;Streamstats&lt;/A&gt;&lt;BR /&gt;
&lt;A href="http://docs.splunk.com/Documentation/Splunk/5.0/SearchReference/Filldown"&gt;Filldown&lt;/A&gt;&lt;BR /&gt;
&lt;A href="http://docs.splunk.com/Documentation/Splunk/5.0/SearchReference/Appendcols"&gt;Appendcols&lt;/A&gt;&lt;BR /&gt;
&lt;A href="http://docs.splunk.com/Documentation/Splunk/5.0/Search/Aboutsubsearches"&gt;Howsubsearcheswork&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 26 Oct 2012 00:10:31 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-do-I-get-the-cumulative-percentage-in-Splunk/m-p/103112#M26663</guid>
      <dc:creator>bmacias84</dc:creator>
      <dc:date>2012-10-26T00:10:31Z</dc:date>
    </item>
    <item>
      <title>Re: How do I get the cumulative percentage in Splunk</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-do-I-get-the-cumulative-percentage-in-Splunk/m-p/103113#M26664</link>
      <description>&lt;P&gt;Hello&lt;/P&gt;

&lt;P&gt;I did solve it up. Did it in a different way, &lt;/P&gt;

&lt;P&gt;...| accum count as total_sum | eval Cum_per = ((total_sum)/Total)*100 . &lt;/P&gt;

&lt;P&gt;Thanks for all the help &lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/19266"&gt;@bmacias84&lt;/a&gt;. I really appreciate your help.&lt;/P&gt;</description>
      <pubDate>Mon, 28 Sep 2020 12:41:50 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-do-I-get-the-cumulative-percentage-in-Splunk/m-p/103113#M26664</guid>
      <dc:creator>theouhuios</dc:creator>
      <dc:date>2020-09-28T12:41:50Z</dc:date>
    </item>
    <item>
      <title>Re: How do I get the cumulative percentage in Splunk</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-do-I-get-the-cumulative-percentage-in-Splunk/m-p/103114#M26665</link>
      <description>&lt;P&gt;@theouhuios, You should post your complete solution.  There always more than one way cheers.&lt;/P&gt;</description>
      <pubDate>Fri, 26 Oct 2012 15:35:09 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-do-I-get-the-cumulative-percentage-in-Splunk/m-p/103114#M26665</guid>
      <dc:creator>bmacias84</dc:creator>
      <dc:date>2012-10-26T15:35:09Z</dc:date>
    </item>
    <item>
      <title>Re: How do I get the cumulative percentage in Splunk</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-do-I-get-the-cumulative-percentage-in-Splunk/m-p/103115#M26666</link>
      <description>&lt;P&gt;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/19266"&gt;@bmacias84&lt;/a&gt; , Here is the complete solution. I am a novice when it comes to splunk &lt;span class="lia-unicode-emoji" title=":face_with_tongue:"&gt;😛&lt;/span&gt; Thanks for the help though.&lt;/P&gt;

&lt;P&gt;sourcetype=incident  earliest=-24h@h latest=@h | stats count by record.affectedCI | sort -count | eventstats sum(count) as total_count | accum count as running | eval Cum_Per= ((running/total_count)*100)| table record.affectedCI , running, Cum_Per | sort - running&lt;/P&gt;</description>
      <pubDate>Mon, 28 Sep 2020 12:42:01 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-do-I-get-the-cumulative-percentage-in-Splunk/m-p/103115#M26666</guid>
      <dc:creator>theouhuios</dc:creator>
      <dc:date>2020-09-28T12:42:01Z</dc:date>
    </item>
    <item>
      <title>Re: How do I get the cumulative percentage in Splunk</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-do-I-get-the-cumulative-percentage-in-Splunk/m-p/103116#M26667</link>
      <description>&lt;P&gt;There is also "eventstats" that can get max of accumative_count in one go&lt;BR /&gt;
  &lt;CODE&gt;&lt;BR /&gt;
| eval time_executing=round(time_executing/1000)&lt;BR /&gt;
| chart count by time_executing span=log2&lt;BR /&gt;
| streamstats sum(count) as accumative_count&lt;BR /&gt;
| eventstats max(accumative_count) as total&lt;BR /&gt;
| eval pr1=round((count/total)*100,2)&lt;BR /&gt;
| eval pr2=round((accumative_count/total)*100,2)&lt;BR /&gt;
&lt;/CODE&gt;, &lt;CODE&gt;&lt;BR /&gt;
| eval time_executing=round(time_executing/1000)&lt;BR /&gt;
| chart count by time_executing span=log2&lt;BR /&gt;
| streamstats sum(count) as accumative_count&lt;BR /&gt;
| eventstats max(accumative_count) as total&lt;BR /&gt;
| eval pr1=round((count/total)*100,2)&lt;BR /&gt;
| eval pr2=round((accumative_count/total)*100,2)&lt;BR /&gt;
&lt;/CODE&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 30 Sep 2020 03:56:50 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-do-I-get-the-cumulative-percentage-in-Splunk/m-p/103116#M26667</guid>
      <dc:creator>mj41</dc:creator>
      <dc:date>2020-09-30T03:56:50Z</dc:date>
    </item>
    <item>
      <title>Re: How do I get the cumulative percentage in Splunk</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-do-I-get-the-cumulative-percentage-in-Splunk/m-p/559264#M158903</link>
      <description>&lt;P&gt;This worked perfectly, thanks &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 13 Jul 2021 13:26:08 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-do-I-get-the-cumulative-percentage-in-Splunk/m-p/559264#M158903</guid>
      <dc:creator>thellmann</dc:creator>
      <dc:date>2021-07-13T13:26:08Z</dc:date>
    </item>
  </channel>
</rss>

