<?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 create a new field after using the chart command in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/How-to-create-a-new-field-after-using-the-chart-command/m-p/181156#M52230</link>
    <description>&lt;P&gt;&lt;EM&gt;EDIT&lt;/EM&gt; - second time's the charm. &lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;index=foo conversion_source=Online OR conversion_source=Offline 
 | bin span=1w _time
 | chart sum(ABC) AS ABC sum(DEF) AS DEF sum(GHI) AS GHI sum(JKL) AS JKL over _time by conversion_source
 | untable date type count
&lt;/CODE&gt;&lt;/PRE&gt;</description>
    <pubDate>Fri, 20 Mar 2015 02:38:31 GMT</pubDate>
    <dc:creator>sideview</dc:creator>
    <dc:date>2015-03-20T02:38:31Z</dc:date>
    <item>
      <title>How to create a new field after using the chart command</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-create-a-new-field-after-using-the-chart-command/m-p/181155#M52229</link>
      <description>&lt;P&gt;Hi Ninjas,&lt;/P&gt;

&lt;P&gt;I have a search which produces a bar chart comparing four different fields week over week:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;index=foo conversion_source=Online OR conversion_source=Offline 
| bin span=1w _time
| chart sum(ABC) AS ABC sum(DEF) AS DEF sum(GHI) AS GHI sum(JKL) AS JKL over _time by conversion_source
| transpose
| search column!=_*
| rename "row 1" AS "Current Week" "row 2" AS "Past Week" column AS "Conversion Source"
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Here is the bar chart:&lt;BR /&gt;
&lt;span class="lia-inline-image-display-wrapper"&gt;&lt;img src="https://community.splunk.com/t5/image/serverpage/image-id/280i6C9FD18D24072FBF/image-size/large?v=v2&amp;amp;px=999" title="alt text" alt="alt text" /&gt;&lt;/span&gt;&lt;/P&gt;

&lt;P&gt;It is ok but the customer wants something a little fancier, like a Bubble Chart or a Punchcard, e.g.&lt;BR /&gt;
&lt;span class="lia-inline-image-display-wrapper"&gt;&lt;img src="https://community.splunk.com/t5/image/serverpage/image-id/281i79D94EBFEA88F0E1/image-size/large?v=v2&amp;amp;px=999" title="alt text" alt="alt text" /&gt;&lt;/span&gt;&lt;/P&gt;

&lt;P&gt;To use the Punchard viz, I need to re-format the output from the following:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;Conversion Source   Current Week    Past Week
ABC: Offline         40262         37334
ABC: Online       36997        36233
DEF: Offline         253865       216674
DEF: Online       561871          572597
GHI: Offline         356971       398079
GHI: Online       243909          226444
JKL: Offline         1275880         1284603
JKL: Online       1225050        1165302
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;to this:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;date            type            count
Current Week    ABC: Offline    40262
Current Week    ABC: Online  36997
Current Week    DEF: Offline    253865
Current Week    DEF: Online  561871
Current Week    GHI: Offline    356971
Current Week    GHI: Online  243909
Current Week    JKL: Offline    1275880
Current Week    JKL: Online  1225050
Past Week      ABC: Offline 37334
Past Week      ABC: Online   36233
Past Week      DEF: Offline 216674
Past Week      DEF: Online   572597
Past Week      GHI: Offline 398079
Past Week      GHI: Online   226444
Past Week      JKL: Offline 1284603
Past Week      JKL: Online   1165302
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;I would greatly appreciate any tips on how to achieve this new tabular output.&lt;/P&gt;

&lt;P&gt;Thanks in advance,&lt;/P&gt;

&lt;P&gt;Luke.&lt;/P&gt;</description>
      <pubDate>Fri, 20 Mar 2015 00:32:46 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-create-a-new-field-after-using-the-chart-command/m-p/181155#M52229</guid>
      <dc:creator>lukeh</dc:creator>
      <dc:date>2015-03-20T00:32:46Z</dc:date>
    </item>
    <item>
      <title>Re: How to create a new field after using the chart command</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-create-a-new-field-after-using-the-chart-command/m-p/181156#M52230</link>
      <description>&lt;P&gt;&lt;EM&gt;EDIT&lt;/EM&gt; - second time's the charm. &lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;index=foo conversion_source=Online OR conversion_source=Offline 
 | bin span=1w _time
 | chart sum(ABC) AS ABC sum(DEF) AS DEF sum(GHI) AS GHI sum(JKL) AS JKL over _time by conversion_source
 | untable date type count
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Fri, 20 Mar 2015 02:38:31 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-create-a-new-field-after-using-the-chart-command/m-p/181156#M52230</guid>
      <dc:creator>sideview</dc:creator>
      <dc:date>2015-03-20T02:38:31Z</dc:date>
    </item>
    <item>
      <title>Re: How to create a new field after using the chart command</title>
      <link>https://community.splunk.com/t5/Splunk-Search/How-to-create-a-new-field-after-using-the-chart-command/m-p/181157#M52231</link>
      <description>&lt;P&gt;Thank you Nick!!!11!!!!!1!!!&lt;/P&gt;

&lt;P&gt;untable did the trick, which reminds me of the undead &lt;span class="lia-unicode-emoji" title=":winking_face:"&gt;😉&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 20 Mar 2015 05:06:55 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/How-to-create-a-new-field-after-using-the-chart-command/m-p/181157#M52231</guid>
      <dc:creator>lukeh</dc:creator>
      <dc:date>2015-03-20T05:06:55Z</dc:date>
    </item>
  </channel>
</rss>

