<?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 JSChart with Post Process in Dashboards &amp; Visualizations</title>
    <link>https://community.splunk.com/t5/Dashboards-Visualizations/JSChart-with-Post-Process/m-p/50466#M43853</link>
    <description>&lt;P&gt;Could someone give a simple example of how to use Post Process with JSChart?&lt;/P&gt;

&lt;P&gt;I want a base search of &lt;EM&gt;index=daldev&lt;/EM&gt;&lt;/P&gt;

&lt;P&gt;Then two charts, the first:&lt;BR /&gt;
&lt;EM&gt;timechart per_second(A) by Action&lt;/EM&gt;&lt;/P&gt;

&lt;P&gt;second:&lt;BR /&gt;
&lt;EM&gt;timechart per_second(B) by Action&lt;/EM&gt;&lt;/P&gt;</description>
    <pubDate>Fri, 30 Nov 2012 12:22:43 GMT</pubDate>
    <dc:creator>matthewcanty</dc:creator>
    <dc:date>2012-11-30T12:22:43Z</dc:date>
    <item>
      <title>JSChart with Post Process</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/JSChart-with-Post-Process/m-p/50466#M43853</link>
      <description>&lt;P&gt;Could someone give a simple example of how to use Post Process with JSChart?&lt;/P&gt;

&lt;P&gt;I want a base search of &lt;EM&gt;index=daldev&lt;/EM&gt;&lt;/P&gt;

&lt;P&gt;Then two charts, the first:&lt;BR /&gt;
&lt;EM&gt;timechart per_second(A) by Action&lt;/EM&gt;&lt;/P&gt;

&lt;P&gt;second:&lt;BR /&gt;
&lt;EM&gt;timechart per_second(B) by Action&lt;/EM&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 30 Nov 2012 12:22:43 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/JSChart-with-Post-Process/m-p/50466#M43853</guid>
      <dc:creator>matthewcanty</dc:creator>
      <dc:date>2012-11-30T12:22:43Z</dc:date>
    </item>
    <item>
      <title>Re: JSChart with Post Process</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/JSChart-with-Post-Process/m-p/50467#M43854</link>
      <description>&lt;P&gt;Well at the simplest level,  you can use those exact searches,  but you have to sneak in a&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;| fields A B Action _time 
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;onto the end in order for the base search to run the field extractions for A and B.  Unless it sees evidence that a given field is necessary for the base search, Splunk wont extract it and therefore it wont exist come post-process time. &lt;/P&gt;

&lt;P&gt;However it's not best-practice to use postprocess in situations where the base search is a simple search for events.  Instead you use stats and as necessary the bin command to make a base search that is itself a transforming search.  This results in better performance and avoids some scaling problems. &lt;/P&gt;

&lt;P&gt;Let's say the final granularity of your timecharts is such that one bucket equals one hour. &lt;/P&gt;

&lt;P&gt;base search: &lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;index=daldev | bin _time span=1h | stats sum(A) as A sum(B) as B count by _time Action
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;postprocess 1: &lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;timechart per_second(A) by Action
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;postprocess 2: &lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;timechart per_second(B) by Action
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Sun, 02 Dec 2012 23:23:39 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/JSChart-with-Post-Process/m-p/50467#M43854</guid>
      <dc:creator>sideview</dc:creator>
      <dc:date>2012-12-02T23:23:39Z</dc:date>
    </item>
  </channel>
</rss>

