<?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: Filter a dashboard table by column values in Dashboards &amp; Visualizations</title>
    <link>https://community.splunk.com/t5/Dashboards-Visualizations/Filter-a-dashboard-table-by-column-values/m-p/115363#M6618</link>
    <description>&lt;P&gt;Hi jasonang - I didn't get a response, but I did file an enhancement request. Case 303365&lt;/P&gt;</description>
    <pubDate>Wed, 30 Dec 2015 20:36:33 GMT</pubDate>
    <dc:creator>bruceclarke</dc:creator>
    <dc:date>2015-12-30T20:36:33Z</dc:date>
    <item>
      <title>Filter a dashboard table by column values</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/Filter-a-dashboard-table-by-column-values/m-p/115359#M6614</link>
      <description>&lt;P&gt;All,&lt;/P&gt;

&lt;P&gt;I have a simple table visualization on a dashboard and I want to have the option to filter down to specific values for each column. For example, I have a column for the disk drive that data is coming from (for some machines this could be a C:, D:, E:, for others just a G:, etc) and I want to only show rows that have disk drive C:.&lt;/P&gt;

&lt;P&gt;Right now I have a selector above the table that lists all the possible drives, sets a form input, and reissues a search for the tables content. That's annoying, since you have to wait for data to return again, even though you already know it's a subset of the data already in the table.&lt;/P&gt;

&lt;P&gt;Does anyone know if there's a way I can filter a table like this without needing to reissue the query? Thanks!&lt;/P&gt;</description>
      <pubDate>Wed, 20 May 2015 23:14:51 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/Filter-a-dashboard-table-by-column-values/m-p/115359#M6614</guid>
      <dc:creator>bruceclarke</dc:creator>
      <dc:date>2015-05-20T23:14:51Z</dc:date>
    </item>
    <item>
      <title>Re: Filter a dashboard table by column values</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/Filter-a-dashboard-table-by-column-values/m-p/115360#M6615</link>
      <description>&lt;H4&gt;Post-process searches&lt;/H4&gt;

&lt;P&gt;Sometimes you end up with a dashboard running searches that are similar. You can save search resources by creating a base search for the dashboard. Panels in the dashboard use a post-process search to further modify the results of a base search. The base search can be a global search for the dashboard or any other search within the dashboard.&lt;/P&gt;

&lt;P&gt;More &lt;A href="http://docs.splunk.com/Documentation/Splunk/6.2.3/Viz/Savedsearches#Post-process_searches"&gt;here&lt;/A&gt;.&lt;/P&gt;

&lt;HR /&gt;

&lt;H4&gt;Post-process limitations&lt;/H4&gt;

&lt;P&gt;Post-process searches have limitations.&lt;/P&gt;

&lt;UL&gt;
&lt;LI&gt;&lt;P&gt;If the base search is a non-transforming search, Splunk Enterprise retains only the first 10,000 events returned. The post-process search does not process events in excess of this 10,000 event limit, silently ignoring them. This results in incomplete data for the post-process search. A transforming search as the base search helps avoid this limitation.&lt;/P&gt;&lt;/LI&gt;
&lt;LI&gt;&lt;P&gt;If the post-processing operation takes too long, it can exceed Splunk Web client’s non-configurable timeout value of 30 seconds. This can result in a timeout due to an unresponsive splunkd daemon/service. This scenario typically happens when you use a non-transforming search as the base search.&lt;/P&gt;&lt;/LI&gt;
&lt;/UL&gt;

&lt;HR /&gt;

&lt;P&gt;From the docs:&lt;/P&gt;

&lt;H4&gt;Form with post-process search for inputs&lt;/H4&gt;

&lt;P&gt;You can use a post-process search to dynamically populate inputs to a form. The following example shows a form with two inputs. The drop-down list, which selects an index to search, defines the choices statically. The drop-down list to select a source type statically defines the default choice but uses a post-process search to dynamically define the other choices.&lt;/P&gt;

&lt;P&gt;&lt;STRONG&gt;Base search for populating the source type dropdown&lt;/STRONG&gt;&lt;BR /&gt;
&lt;CODE&gt;index=_internal | stats count by sourcetype&lt;/CODE&gt;&lt;/P&gt;

&lt;P&gt;&lt;STRONG&gt;Post process for dropdown input&lt;/STRONG&gt;&lt;BR /&gt;
&lt;CODE&gt;| search sourcetype=splunkd*&lt;/CODE&gt;&lt;/P&gt;

&lt;P&gt;&lt;IMG src="http://docs.splunk.com/images/8/82/Viz_form_post_process.png" alt="alt text" /&gt;&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;&amp;lt;form&amp;gt;
  &amp;lt;label&amp;gt;Post Process in Form Inputs&amp;lt;/label&amp;gt;

  &amp;lt;!-- Global search for post process by dropdown input --&amp;gt;
  &amp;lt;!-- Search uses stats command to limit results to less than 10,000 limit --&amp;gt;
  &amp;lt;search id="searchInput"&amp;gt;
    &amp;lt;query&amp;gt;index=_internal | stats count by sourcetype&amp;lt;/query&amp;gt;
    &amp;lt;earliest&amp;gt;-60min&amp;lt;/earliest&amp;gt;
    &amp;lt;latest&amp;gt;now&amp;lt;/latest&amp;gt;
  &amp;lt;/search&amp;gt;

  &amp;lt;fieldset submitButton="false"&amp;gt;

    &amp;lt;!-- Select an index from two static choices --&amp;gt;
    &amp;lt;input type="dropdown" token="index_tok" searchWhenChanged="true"&amp;gt;
      &amp;lt;label&amp;gt;Select an index to search&amp;lt;/label&amp;gt;
      &amp;lt;choice value="_internal"&amp;gt;Internal&amp;lt;/choice&amp;gt;
      &amp;lt;choice value="*"&amp;gt;All public indexes&amp;lt;/choice&amp;gt;
      &amp;lt;default&amp;gt;_internal&amp;lt;/default&amp;gt;
    &amp;lt;/input&amp;gt;

    &amp;lt;!-- Dynamically populate choices --&amp;gt;    
    &amp;lt;input type="dropdown" token="sourcetype_tok" searchWhenChanged="true"&amp;gt;
      &amp;lt;label&amp;gt;Select a source type&amp;lt;/label&amp;gt;

      &amp;lt;!-- default choice is all sourcetypes --&amp;gt;
      &amp;lt;choice value="*"&amp;gt;All sourcetypes&amp;lt;/choice&amp;gt;
      &amp;lt;default&amp;gt;*&amp;lt;/default&amp;gt;

      &amp;lt;!-- Post-process search to dynamically populate choices --&amp;gt;
      &amp;lt;search base="searchInput"&amp;gt;
        &amp;lt;query&amp;gt;search sourcetype=splunkd*&amp;lt;/query&amp;gt;
      &amp;lt;/search&amp;gt;
      &amp;lt;fieldForLabel&amp;gt;sourcetype&amp;lt;/fieldForLabel&amp;gt;
      &amp;lt;fieldForValue&amp;gt;sourcetype&amp;lt;/fieldForValue&amp;gt;

    &amp;lt;/input&amp;gt;
    &amp;lt;input type="time" token="time_tok" searchWhenChanged="true"&amp;gt;
      &amp;lt;label&amp;gt;&amp;lt;/label&amp;gt;
      &amp;lt;default&amp;gt;
        &amp;lt;earliest&amp;gt;-24h@h&amp;lt;/earliest&amp;gt;
        &amp;lt;latest&amp;gt;now&amp;lt;/latest&amp;gt;
      &amp;lt;/default&amp;gt;
    &amp;lt;/input&amp;gt;
  &amp;lt;/fieldset&amp;gt;
  &amp;lt;row&amp;gt;
    &amp;lt;panel&amp;gt;
      &amp;lt;chart&amp;gt;
        &amp;lt;title&amp;gt;Chart&amp;lt;/title&amp;gt;
        &amp;lt;search&amp;gt;
          &amp;lt;query&amp;gt;
            index=$index_tok$ sourcetype=$sourcetype_tok$ | timechart count
          &amp;lt;/query&amp;gt;
          &amp;lt;earliest&amp;gt;$time_tok.earliest$&amp;lt;/earliest&amp;gt;
          &amp;lt;latest&amp;gt;$time_tok.latest$&amp;lt;/latest&amp;gt;
        &amp;lt;/search&amp;gt;
      &amp;lt;/chart&amp;gt;
    &amp;lt;/panel&amp;gt;
  &amp;lt;/row&amp;gt;
&amp;lt;/form&amp;gt;
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Thu, 21 May 2015 01:21:31 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/Filter-a-dashboard-table-by-column-values/m-p/115360#M6615</guid>
      <dc:creator>aljohnson_splun</dc:creator>
      <dc:date>2015-05-21T01:21:31Z</dc:date>
    </item>
    <item>
      <title>Re: Filter a dashboard table by column values</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/Filter-a-dashboard-table-by-column-values/m-p/115361#M6616</link>
      <description>&lt;P&gt;I don't think this is quite what I want.&lt;/P&gt;

&lt;P&gt;Imagine I have a search that returns a table of restaurant information. I have a zip code input that drives the initial population of the table (e.g. get me all restaurants in that zip code). The table is then populated with a bunch of columns, two of which are "cuisine" and "average price." I want to filter down the table to only Italian cuisine and order by average price. Right now, I need to have an input that reissues the query with the "Italian" filter.&lt;/P&gt;

&lt;P&gt;All I should need to do is have a filter on the table. Issuing a separate query is unnecessary and adds unneeded load time to the dashboard. If this functionality doesn't exist, I can file an enhancement request.&lt;/P&gt;</description>
      <pubDate>Thu, 21 May 2015 17:06:15 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/Filter-a-dashboard-table-by-column-values/m-p/115361#M6616</guid>
      <dc:creator>bruceclarke</dc:creator>
      <dc:date>2015-05-21T17:06:15Z</dc:date>
    </item>
    <item>
      <title>Re: Filter a dashboard table by column values</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/Filter-a-dashboard-table-by-column-values/m-p/115362#M6617</link>
      <description>&lt;P&gt;Bruce, did you get this answered? I have the same question. Thanks.&lt;/P&gt;</description>
      <pubDate>Wed, 30 Dec 2015 20:24:51 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/Filter-a-dashboard-table-by-column-values/m-p/115362#M6617</guid>
      <dc:creator>jasonang</dc:creator>
      <dc:date>2015-12-30T20:24:51Z</dc:date>
    </item>
    <item>
      <title>Re: Filter a dashboard table by column values</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/Filter-a-dashboard-table-by-column-values/m-p/115363#M6618</link>
      <description>&lt;P&gt;Hi jasonang - I didn't get a response, but I did file an enhancement request. Case 303365&lt;/P&gt;</description>
      <pubDate>Wed, 30 Dec 2015 20:36:33 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/Filter-a-dashboard-table-by-column-values/m-p/115363#M6618</guid>
      <dc:creator>bruceclarke</dc:creator>
      <dc:date>2015-12-30T20:36:33Z</dc:date>
    </item>
    <item>
      <title>Re: Filter a dashboard table by column values</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/Filter-a-dashboard-table-by-column-values/m-p/115364#M6619</link>
      <description>&lt;P&gt;Very late response, you might have figured a solution, but this is what I did for one of our use cases.  &lt;/P&gt;

&lt;P&gt;With text input with token "filtertext" and below post process search,  can filter all the columns in the table.&lt;/P&gt;

&lt;P&gt;| foreach * [eval filter=if((filter=1 OR match('&amp;lt;&amp;gt;',"(?i).&lt;EM&gt;$filtertext$.&lt;/EM&gt;")),1,0)] | search filter=1 | fields - filter&lt;/P&gt;</description>
      <pubDate>Mon, 27 Mar 2017 17:51:00 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/Filter-a-dashboard-table-by-column-values/m-p/115364#M6619</guid>
      <dc:creator>kyaparla</dc:creator>
      <dc:date>2017-03-27T17:51:00Z</dc:date>
    </item>
  </channel>
</rss>

