<?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: sum of all the fields and aggregate sum in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/sum-of-all-the-fields-and-aggregate-sum/m-p/184937#M53257</link>
    <description>&lt;P&gt;Like this:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt; my_search ... | eval total_bytes = exact(val_1 + val_2) | stats sum(total_bytes) by source destination
&lt;/CODE&gt;&lt;/PRE&gt;</description>
    <pubDate>Tue, 30 Jun 2015 21:43:47 GMT</pubDate>
    <dc:creator>woodcock</dc:creator>
    <dc:date>2015-06-30T21:43:47Z</dc:date>
    <item>
      <title>sum of all the fields and aggregate sum</title>
      <link>https://community.splunk.com/t5/Splunk-Search/sum-of-all-the-fields-and-aggregate-sum/m-p/184936#M53256</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;

&lt;P&gt;I am having a tough time in creating overall sum and aggregate sum. Here is my issue:&lt;/P&gt;

&lt;P&gt;I have multiple values between client-server:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;source destination client_to_server_bytes server_to_client_bytes
    A --   B                10                                   12
    A --   B                10                                   10
    A --   C                50                                   30
    C --   D                15                                   15
    c --   D                10                                   10
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;I want to create a table with addition of two values in all occurrences. And final value would have addition of all the additions:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;A -- B 42
A -- C 80
C -- D 50
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;To get first addition I did:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;my_search ... | eval total_bytes = exact(val_1 + val_2) | table source destination total_bytes
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;This correctly gave me following result:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;A -- B 22
A -- B 20
...and so on
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Now how do I combine them to form a single result?&lt;/P&gt;</description>
      <pubDate>Tue, 30 Jun 2015 21:39:58 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/sum-of-all-the-fields-and-aggregate-sum/m-p/184936#M53256</guid>
      <dc:creator>shrirangphadke</dc:creator>
      <dc:date>2015-06-30T21:39:58Z</dc:date>
    </item>
    <item>
      <title>Re: sum of all the fields and aggregate sum</title>
      <link>https://community.splunk.com/t5/Splunk-Search/sum-of-all-the-fields-and-aggregate-sum/m-p/184937#M53257</link>
      <description>&lt;P&gt;Like this:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt; my_search ... | eval total_bytes = exact(val_1 + val_2) | stats sum(total_bytes) by source destination
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Tue, 30 Jun 2015 21:43:47 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/sum-of-all-the-fields-and-aggregate-sum/m-p/184937#M53257</guid>
      <dc:creator>woodcock</dc:creator>
      <dc:date>2015-06-30T21:43:47Z</dc:date>
    </item>
    <item>
      <title>Re: sum of all the fields and aggregate sum</title>
      <link>https://community.splunk.com/t5/Splunk-Search/sum-of-all-the-fields-and-aggregate-sum/m-p/184938#M53258</link>
      <description>&lt;P&gt;It was easy! I am really dumb.. Anyways Thanks for your help !!&lt;/P&gt;</description>
      <pubDate>Tue, 30 Jun 2015 21:49:54 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/sum-of-all-the-fields-and-aggregate-sum/m-p/184938#M53258</guid>
      <dc:creator>shrirangphadke</dc:creator>
      <dc:date>2015-06-30T21:49:54Z</dc:date>
    </item>
    <item>
      <title>Re: sum of all the fields and aggregate sum</title>
      <link>https://community.splunk.com/t5/Splunk-Search/sum-of-all-the-fields-and-aggregate-sum/m-p/184939#M53259</link>
      <description>&lt;P&gt;So am I but Splunk makes even dummies look brilliant!&lt;/P&gt;</description>
      <pubDate>Tue, 30 Jun 2015 21:54:41 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/sum-of-all-the-fields-and-aggregate-sum/m-p/184939#M53259</guid>
      <dc:creator>woodcock</dc:creator>
      <dc:date>2015-06-30T21:54:41Z</dc:date>
    </item>
    <item>
      <title>Re: sum of all the fields and aggregate sum</title>
      <link>https://community.splunk.com/t5/Splunk-Search/sum-of-all-the-fields-and-aggregate-sum/m-p/184940#M53260</link>
      <description>&lt;P&gt;very true !&lt;/P&gt;</description>
      <pubDate>Tue, 30 Jun 2015 22:06:32 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/sum-of-all-the-fields-and-aggregate-sum/m-p/184940#M53260</guid>
      <dc:creator>shrirangphadke</dc:creator>
      <dc:date>2015-06-30T22:06:32Z</dc:date>
    </item>
  </channel>
</rss>

