<?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: Make operations between two columns in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/How-to-Make-operations-between-two-columns/m-p/598500#M208407</link>
    <description>&lt;P&gt;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/161352"&gt;@gcusello&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Could you please give me an example? What do you mean with "fixed"?&lt;/P&gt;</description>
    <pubDate>Thu, 19 May 2022 13:56:44 GMT</pubDate>
    <dc:creator>nalagito</dc:creator>
    <dc:date>2022-05-19T13:56:44Z</dc:date>
    <item>
      <title>How to Make operations between two columns</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-Make-operations-between-two-columns/m-p/598490#M208404</link>
      <description>&lt;P&gt;Hello, I have this query:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;LI-CODE lang="markup"&gt;| mstats avg(_value) as packets WHERE index=metrics_index sourcetype=network_metrics (metric_name=*.out) ((metric_name="InterfaceEthernetA.*" OR metric_name="InterfaceEthernetB.*") AND (host="hostA" OR host="hostB")) span=1m by metric_name,host 
| rex field=metric_name ".*InterfaceEthernet(?&amp;lt;mn&amp;gt;\d_\d*)"
| eval kbits=packets*8/1000
| timechart span=30m sum(kbits) by mn&lt;/LI-CODE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;It returns this results:&lt;/P&gt;
&lt;DIV class=""&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="img.jpeg" style="width: 999px;"&gt;&lt;img src="https://community.splunk.com/t5/image/serverpage/image-id/19712iF486690F7DA32EBC/image-size/large?v=v2&amp;amp;px=999" role="button" title="img.jpeg" alt="img.jpeg" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;From those results, I would like to make operations generating another column with those results...&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;For example: (ColumnA - ColumnB) / ColumnA * 100&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;How could I do that?&lt;/P&gt;</description>
      <pubDate>Thu, 19 May 2022 16:15:43 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-Make-operations-between-two-columns/m-p/598490#M208404</guid>
      <dc:creator>nalagito</dc:creator>
      <dc:date>2022-05-19T16:15:43Z</dc:date>
    </item>
    <item>
      <title>Re: Make operations between two columns</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-Make-operations-between-two-columns/m-p/598494#M208405</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/245995"&gt;@nalagito&lt;/a&gt;,&lt;/P&gt;&lt;P&gt;if the values of ColumnA and ColumnB are fixed, you can use the eval command to make the calculation you need.&lt;/P&gt;&lt;P&gt;If instead they aren't fixed, is much more complicated.&lt;/P&gt;&lt;P&gt;Ciao.&lt;/P&gt;&lt;P&gt;Giuseppe&lt;/P&gt;</description>
      <pubDate>Thu, 19 May 2022 13:40:23 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-Make-operations-between-two-columns/m-p/598494#M208405</guid>
      <dc:creator>gcusello</dc:creator>
      <dc:date>2022-05-19T13:40:23Z</dc:date>
    </item>
    <item>
      <title>Re: Make operations between two columns</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-Make-operations-between-two-columns/m-p/598500#M208407</link>
      <description>&lt;P&gt;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/161352"&gt;@gcusello&lt;/a&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Could you please give me an example? What do you mean with "fixed"?&lt;/P&gt;</description>
      <pubDate>Thu, 19 May 2022 13:56:44 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-Make-operations-between-two-columns/m-p/598500#M208407</guid>
      <dc:creator>nalagito</dc:creator>
      <dc:date>2022-05-19T13:56:44Z</dc:date>
    </item>
    <item>
      <title>Re: Make operations between two columns</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-Make-operations-between-two-columns/m-p/598519#M208413</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/245995"&gt;@nalagito&lt;/a&gt;,&lt;/P&gt;&lt;P&gt;if the values of mn are always:&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;my_mn1,&lt;/LI&gt;&lt;LI&gt;my_mn2.&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;in this case you can make operations using my_mn1 and my_mn2 as column name.&lt;/P&gt;&lt;P&gt;Ciao.&lt;/P&gt;&lt;P&gt;Giuseppe&lt;/P&gt;</description>
      <pubDate>Thu, 19 May 2022 14:52:14 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-Make-operations-between-two-columns/m-p/598519#M208413</guid>
      <dc:creator>gcusello</dc:creator>
      <dc:date>2022-05-19T14:52:14Z</dc:date>
    </item>
  </channel>
</rss>

