<?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: create table/chart like excel pivot in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/create-table-chart-like-excel-pivot/m-p/152026#M42608</link>
    <description>&lt;P&gt;Try something like this&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;your base search giving fields Organization Unit Ticket_state Severity Year Count
| eval RowLabel=Organiation."-".Unit."-".Ticket_state."-".Severity | chart sum(count) as count over RowLabel by Year 
| addtotals fieldname="Total" 2* | eval Org=mvindex(split(RowLabel,"-"),0)| appendpipe [| stats sum(*) as * by Org | eval RowLabel=Org."Z"] 
| sort RowLabel | fields - Org
&lt;/CODE&gt;&lt;/PRE&gt;</description>
    <pubDate>Fri, 31 Jul 2015 18:23:49 GMT</pubDate>
    <dc:creator>somesoni2</dc:creator>
    <dc:date>2015-07-31T18:23:49Z</dc:date>
    <item>
      <title>create table/chart like excel pivot</title>
      <link>https://community.splunk.com/t5/Splunk-Search/create-table-chart-like-excel-pivot/m-p/152024#M42606</link>
      <description>&lt;P&gt;I need to make a chart of nested columns like we can do in excel pivot.&lt;/P&gt;

&lt;P&gt;Sample data and required view is given in the screenshot:&lt;/P&gt;

&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="alt text"&gt;&lt;img src="https://community.splunk.com/t5/image/serverpage/image-id/525i0C2D92C072A9988B/image-size/large?v=v2&amp;amp;px=999" role="button" title="alt text" alt="alt text" /&gt;&lt;/span&gt;&lt;/P&gt;

&lt;P&gt;Is it possible to achieve this in SPLUNK? If not, what best can be done in this case? Please advise.&lt;/P&gt;

&lt;P&gt;Thank you so much!&lt;/P&gt;</description>
      <pubDate>Fri, 31 Jul 2015 17:37:46 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/create-table-chart-like-excel-pivot/m-p/152024#M42606</guid>
      <dc:creator>ishaanshekhar</dc:creator>
      <dc:date>2015-07-31T17:37:46Z</dc:date>
    </item>
    <item>
      <title>Re: create table/chart like excel pivot</title>
      <link>https://community.splunk.com/t5/Splunk-Search/create-table-chart-like-excel-pivot/m-p/152025#M42607</link>
      <description>&lt;P&gt;Take a look at the &lt;CODE&gt;appendpipe&lt;/CODE&gt; command. I think it will get you started.&lt;/P&gt;</description>
      <pubDate>Fri, 31 Jul 2015 18:20:39 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/create-table-chart-like-excel-pivot/m-p/152025#M42607</guid>
      <dc:creator>lguinn2</dc:creator>
      <dc:date>2015-07-31T18:20:39Z</dc:date>
    </item>
    <item>
      <title>Re: create table/chart like excel pivot</title>
      <link>https://community.splunk.com/t5/Splunk-Search/create-table-chart-like-excel-pivot/m-p/152026#M42608</link>
      <description>&lt;P&gt;Try something like this&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;your base search giving fields Organization Unit Ticket_state Severity Year Count
| eval RowLabel=Organiation."-".Unit."-".Ticket_state."-".Severity | chart sum(count) as count over RowLabel by Year 
| addtotals fieldname="Total" 2* | eval Org=mvindex(split(RowLabel,"-"),0)| appendpipe [| stats sum(*) as * by Org | eval RowLabel=Org."Z"] 
| sort RowLabel | fields - Org
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Fri, 31 Jul 2015 18:23:49 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/create-table-chart-like-excel-pivot/m-p/152026#M42608</guid>
      <dc:creator>somesoni2</dc:creator>
      <dc:date>2015-07-31T18:23:49Z</dc:date>
    </item>
    <item>
      <title>Re: create table/chart like excel pivot</title>
      <link>https://community.splunk.com/t5/Splunk-Search/create-table-chart-like-excel-pivot/m-p/152027#M42609</link>
      <description>&lt;P&gt;Thanks a lot, somesoni2! Your solution worked nicely and is giving correct results...&lt;/P&gt;

&lt;P&gt;However, for some reason the values under RowLabel are coming in one row and are not grouped. And some values under RowLabel column have 'Z' appended in the end.&lt;/P&gt;

&lt;P&gt;Please advise. Thank you!&lt;/P&gt;

&lt;P&gt;Not able to upload the screenshot, so pasting values here:&lt;/P&gt;

&lt;P&gt;RowLabel    2011    2012    2013    2014    2015    Total&lt;BR /&gt;
Computer Management-Financial Department-3-Active               1   8   9&lt;BR /&gt;
Science Management-Physics Department-3-Deferred - Other                1       1&lt;BR /&gt;
Engineering Management-IT Department-3-Queued                   1   1&lt;BR /&gt;
Chemistry ManagementZ                                                                       2   9   11&lt;/P&gt;</description>
      <pubDate>Mon, 03 Aug 2015 17:14:06 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/create-table-chart-like-excel-pivot/m-p/152027#M42609</guid>
      <dc:creator>ishaanshekhar</dc:creator>
      <dc:date>2015-08-03T17:14:06Z</dc:date>
    </item>
  </channel>
</rss>

