<?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 How to timechart percentage value made by stats or eval in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/How-to-timechart-percentage-value-made-by-stats-or-eval/m-p/542799#M153759</link>
    <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Is there right way to show timechart result span as 1day of percentage value which is calculated by stats or eval??&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;We have public ip total and used data as number currently. And those data is splited by data center.&amp;nbsp;&lt;/P&gt;&lt;P&gt;So, I want to use data center as token while showing result data.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;If I set data center as *, I want to get sum of every used data and total data of data center, and make it as percentage data like round(used / total * 100 , 2) and timechart those data..&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I was trying to make the right command but I can't get any result with my command.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I tried like this.&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;my base search data_center IN ($TOKEN$)
|  bucket span=1d _time 
| stats sum('ip.used') as used, sum('ip.total') as total by _time
| eval usage=round(used/total * 100, 2)
| timechart span=1d limit=0 values(usage)&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I can't get the usage result with those command.. Could anyone let me try with right way??&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thank you..&lt;/P&gt;</description>
    <pubDate>Mon, 08 Mar 2021 09:07:25 GMT</pubDate>
    <dc:creator>splunkkid</dc:creator>
    <dc:date>2021-03-08T09:07:25Z</dc:date>
    <item>
      <title>How to timechart percentage value made by stats or eval</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-timechart-percentage-value-made-by-stats-or-eval/m-p/542799#M153759</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Is there right way to show timechart result span as 1day of percentage value which is calculated by stats or eval??&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;We have public ip total and used data as number currently. And those data is splited by data center.&amp;nbsp;&lt;/P&gt;&lt;P&gt;So, I want to use data center as token while showing result data.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;If I set data center as *, I want to get sum of every used data and total data of data center, and make it as percentage data like round(used / total * 100 , 2) and timechart those data..&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I was trying to make the right command but I can't get any result with my command.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I tried like this.&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;my base search data_center IN ($TOKEN$)
|  bucket span=1d _time 
| stats sum('ip.used') as used, sum('ip.total') as total by _time
| eval usage=round(used/total * 100, 2)
| timechart span=1d limit=0 values(usage)&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I can't get the usage result with those command.. Could anyone let me try with right way??&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thank you..&lt;/P&gt;</description>
      <pubDate>Mon, 08 Mar 2021 09:07:25 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-timechart-percentage-value-made-by-stats-or-eval/m-p/542799#M153759</guid>
      <dc:creator>splunkkid</dc:creator>
      <dc:date>2021-03-08T09:07:25Z</dc:date>
    </item>
    <item>
      <title>Re: How to timechart percentage value made by stats or eval</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-timechart-percentage-value-made-by-stats-or-eval/m-p/542834#M153765</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/225778"&gt;@splunkkid&lt;/a&gt;,&lt;/P&gt;&lt;P&gt;Can you please provide a screenshot of result before timechart command? Do you get output from stats command?&lt;/P&gt;</description>
      <pubDate>Mon, 08 Mar 2021 14:30:10 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-timechart-percentage-value-made-by-stats-or-eval/m-p/542834#M153765</guid>
      <dc:creator>scelikok</dc:creator>
      <dc:date>2021-03-08T14:30:10Z</dc:date>
    </item>
    <item>
      <title>Re: How to timechart percentage value made by stats or eval</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-timechart-percentage-value-made-by-stats-or-eval/m-p/542925#M153796</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I checked my command again,.. and I solved it by changing&amp;nbsp; '' to "".&lt;/P&gt;&lt;P&gt;Like sum('ip.used') to sum("ip.used") .&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thank you.&lt;/P&gt;</description>
      <pubDate>Tue, 09 Mar 2021 00:31:12 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-timechart-percentage-value-made-by-stats-or-eval/m-p/542925#M153796</guid>
      <dc:creator>splunkkid</dc:creator>
      <dc:date>2021-03-09T00:31:12Z</dc:date>
    </item>
  </channel>
</rss>

