<?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 join two charts in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/how-to-add-calculated-fields-into-a-chart/m-p/582186#M202799</link>
    <description>&lt;P&gt;Oops thanks&amp;nbsp;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/225168"&gt;@ITWhisperer&lt;/a&gt;&amp;nbsp;pointing out the typo&lt;/P&gt;</description>
    <pubDate>Sun, 23 Jan 2022 23:24:47 GMT</pubDate>
    <dc:creator>bowesmana</dc:creator>
    <dc:date>2022-01-23T23:24:47Z</dc:date>
    <item>
      <title>how to add calculated fields into a chart</title>
      <link>https://community.splunk.com/t5/Splunk-Search/how-to-add-calculated-fields-into-a-chart/m-p/581796#M202677</link>
      <description>&lt;P&gt;I am trying to add 2 new fields into a chart, which is calculated by the exisiting columns in the following chart. Basically I want to add A3=A2/A1, and B3=B2/B1:&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="chongdong_0-1642649972961.png" style="width: 400px;"&gt;&lt;img src="https://community.splunk.com/t5/image/serverpage/image-id/17629i6C9A38E0EB26425F/image-size/medium?v=v2&amp;amp;px=400" role="button" title="chongdong_0-1642649972961.png" alt="chongdong_0-1642649972961.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Can anyone suggest which command to use?&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 20 Jan 2022 03:41:23 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/how-to-add-calculated-fields-into-a-chart/m-p/581796#M202677</guid>
      <dc:creator>chongdong</dc:creator>
      <dc:date>2022-01-20T03:41:23Z</dc:date>
    </item>
    <item>
      <title>Re: how to join two charts</title>
      <link>https://community.splunk.com/t5/Splunk-Search/how-to-add-calculated-fields-into-a-chart/m-p/581803#M202680</link>
      <description>&lt;P&gt;Can you provide the query you are using? What happens when you tried what you tried?&lt;/P&gt;</description>
      <pubDate>Thu, 20 Jan 2022 03:40:58 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/how-to-add-calculated-fields-into-a-chart/m-p/581803#M202680</guid>
      <dc:creator>bowesmana</dc:creator>
      <dc:date>2022-01-20T03:40:58Z</dc:date>
    </item>
    <item>
      <title>Re: how to join two charts</title>
      <link>https://community.splunk.com/t5/Splunk-Search/how-to-add-calculated-fields-into-a-chart/m-p/581804#M202681</link>
      <description>&lt;P&gt;Just found I can directly add sum(___) and dc(___) inside chart command which solved my previous problem lol! Thanks for looking into it though. Now I have a follow up quesion about my post-analysis for adding calculated fileds into the same chart...&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 20 Jan 2022 03:45:26 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/how-to-add-calculated-fields-into-a-chart/m-p/581804#M202681</guid>
      <dc:creator>chongdong</dc:creator>
      <dc:date>2022-01-20T03:45:26Z</dc:date>
    </item>
    <item>
      <title>Re: how to join two charts</title>
      <link>https://community.splunk.com/t5/Splunk-Search/how-to-add-calculated-fields-into-a-chart/m-p/581809#M202684</link>
      <description>&lt;P&gt;Try this - replace your last chart statement with these two lines - the chart just is renaming the fields and the foreach is doing the calc, i.e. Ratio=TintCount/Zones&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;| chart sum(tint_count) as TintCount dc(zonename) as Zones by direction type
| foreach TintCount* [ eval "Ratio&amp;lt;&amp;lt;MATCHSTR&amp;gt;&amp;gt;"='&amp;lt;&amp;lt;FIELD&amp;gt;&amp;gt;'/'Zones&amp;lt;&amp;lt;MATCHSTR&amp;gt;&amp;gt;' ]&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 20 Jan 2022 04:20:46 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/how-to-add-calculated-fields-into-a-chart/m-p/581809#M202684</guid>
      <dc:creator>bowesmana</dc:creator>
      <dc:date>2022-01-20T04:20:46Z</dc:date>
    </item>
    <item>
      <title>Re: how to join two charts</title>
      <link>https://community.splunk.com/t5/Splunk-Search/how-to-add-calculated-fields-into-a-chart/m-p/581830#M202689</link>
      <description>&lt;P&gt;Thanks for the suggestion! But it doesn't seem to work&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="chongdong_0-1642660489110.png" style="width: 400px;"&gt;&lt;img src="https://community.splunk.com/t5/image/serverpage/image-id/17634i9511B74407B85CF3/image-size/medium?v=v2&amp;amp;px=400" role="button" title="chongdong_0-1642660489110.png" alt="chongdong_0-1642660489110.png" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;Is the foreach command supposed to insert a new column called Ratio in this case?&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 20 Jan 2022 06:35:25 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/how-to-add-calculated-fields-into-a-chart/m-p/581830#M202689</guid>
      <dc:creator>chongdong</dc:creator>
      <dc:date>2022-01-20T06:35:25Z</dc:date>
    </item>
    <item>
      <title>Re: how to join two charts</title>
      <link>https://community.splunk.com/t5/Splunk-Search/how-to-add-calculated-fields-into-a-chart/m-p/581845#M202690</link>
      <description>&lt;P&gt;dc(zonename) should be dc(zoneName)&lt;/P&gt;</description>
      <pubDate>Thu, 20 Jan 2022 07:12:50 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/how-to-add-calculated-fields-into-a-chart/m-p/581845#M202690</guid>
      <dc:creator>ITWhisperer</dc:creator>
      <dc:date>2022-01-20T07:12:50Z</dc:date>
    </item>
    <item>
      <title>Re: how to join two charts</title>
      <link>https://community.splunk.com/t5/Splunk-Search/how-to-add-calculated-fields-into-a-chart/m-p/582186#M202799</link>
      <description>&lt;P&gt;Oops thanks&amp;nbsp;&lt;a href="https://community.splunk.com/t5/user/viewprofilepage/user-id/225168"&gt;@ITWhisperer&lt;/a&gt;&amp;nbsp;pointing out the typo&lt;/P&gt;</description>
      <pubDate>Sun, 23 Jan 2022 23:24:47 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/how-to-add-calculated-fields-into-a-chart/m-p/582186#M202799</guid>
      <dc:creator>bowesmana</dc:creator>
      <dc:date>2022-01-23T23:24:47Z</dc:date>
    </item>
  </channel>
</rss>

