<?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: Dashboard drop down and input option in Splunk Search</title>
    <link>https://community.splunk.com/t5/Splunk-Search/Dashboard-drop-down-and-input-option/m-p/123789#M33443</link>
    <description>&lt;P&gt;Hi  sushmitha,&lt;/P&gt;

&lt;P&gt;You can create a Dropdown or text box using this simple xml code to Display the results in a table. The following is the complete dynamic form search:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;&amp;lt;form&amp;gt;
  &amp;lt;label&amp;gt;Username&amp;lt;/label&amp;gt;
  &amp;lt;searchTemplate&amp;gt;sourcetype=logins $username$&amp;lt;/searchTemplate&amp;gt;  
  &amp;lt;fieldset&amp;gt;
    &amp;lt;input type="dropdown" token="username"&amp;gt;
       &amp;lt;label&amp;gt;Select Name&amp;lt;/label&amp;gt;
       &amp;lt;populatingSearch fieldForValue="user" fieldForLabel="user"&amp;gt;
          &amp;lt;![CDATA[sourcetype=YourSourcetype
          | stats count by user]]&amp;gt;
        &amp;lt;/populatingSearch&amp;gt;
    &amp;lt;/input&amp;gt;
  &amp;lt;/fieldset&amp;gt;

  &amp;lt;row&amp;gt;
    &amp;lt;table&amp;gt;
      &amp;lt;title&amp;gt;User&amp;lt;/title&amp;gt;
        &amp;lt;option name="showPager"&amp;gt;true&amp;lt;/option&amp;gt;
      &amp;lt;/table&amp;gt;
  &amp;lt;/row&amp;gt;
&amp;lt;/form&amp;gt;
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;If You have your customize search wich populate your dashboard, yo can replace the&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt; &amp;lt;row&amp;gt; ....  &amp;lt;/row&amp;gt; with the below code:

&amp;lt;row&amp;gt;
    &amp;lt;panel&amp;gt;
        &amp;lt;event&amp;gt;
                  &amp;lt;searchString&amp;gt;index=your_Index  User=$username$ | ....  &amp;lt;/searchString&amp;gt;
            &amp;lt;earliestTime/&amp;gt;
            &amp;lt;latestTime/&amp;gt;
          &amp;lt;/event&amp;gt;
      &amp;lt;/panel&amp;gt;
  &amp;lt;/row&amp;gt;
&lt;/CODE&gt;&lt;/PRE&gt;</description>
    <pubDate>Tue, 31 Mar 2015 19:21:07 GMT</pubDate>
    <dc:creator>Patient</dc:creator>
    <dc:date>2015-03-31T19:21:07Z</dc:date>
    <item>
      <title>Dashboard drop down and input option</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Dashboard-drop-down-and-input-option/m-p/123788#M33442</link>
      <description>&lt;P&gt;I have created a dashboard with hourly sum(added) values for all users. In the dashboard I want to give the option of drop down to select the user name or a text box where they can enter the name of the user and the graph has to display the result of this user alone. &lt;BR /&gt;
How can I create a drop box or text box and pass the value to the query?  &lt;/P&gt;</description>
      <pubDate>Tue, 31 Mar 2015 19:02:57 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Dashboard-drop-down-and-input-option/m-p/123788#M33442</guid>
      <dc:creator>sushmitha_mj</dc:creator>
      <dc:date>2015-03-31T19:02:57Z</dc:date>
    </item>
    <item>
      <title>Re: Dashboard drop down and input option</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Dashboard-drop-down-and-input-option/m-p/123789#M33443</link>
      <description>&lt;P&gt;Hi  sushmitha,&lt;/P&gt;

&lt;P&gt;You can create a Dropdown or text box using this simple xml code to Display the results in a table. The following is the complete dynamic form search:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;&amp;lt;form&amp;gt;
  &amp;lt;label&amp;gt;Username&amp;lt;/label&amp;gt;
  &amp;lt;searchTemplate&amp;gt;sourcetype=logins $username$&amp;lt;/searchTemplate&amp;gt;  
  &amp;lt;fieldset&amp;gt;
    &amp;lt;input type="dropdown" token="username"&amp;gt;
       &amp;lt;label&amp;gt;Select Name&amp;lt;/label&amp;gt;
       &amp;lt;populatingSearch fieldForValue="user" fieldForLabel="user"&amp;gt;
          &amp;lt;![CDATA[sourcetype=YourSourcetype
          | stats count by user]]&amp;gt;
        &amp;lt;/populatingSearch&amp;gt;
    &amp;lt;/input&amp;gt;
  &amp;lt;/fieldset&amp;gt;

  &amp;lt;row&amp;gt;
    &amp;lt;table&amp;gt;
      &amp;lt;title&amp;gt;User&amp;lt;/title&amp;gt;
        &amp;lt;option name="showPager"&amp;gt;true&amp;lt;/option&amp;gt;
      &amp;lt;/table&amp;gt;
  &amp;lt;/row&amp;gt;
&amp;lt;/form&amp;gt;
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;If You have your customize search wich populate your dashboard, yo can replace the&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt; &amp;lt;row&amp;gt; ....  &amp;lt;/row&amp;gt; with the below code:

&amp;lt;row&amp;gt;
    &amp;lt;panel&amp;gt;
        &amp;lt;event&amp;gt;
                  &amp;lt;searchString&amp;gt;index=your_Index  User=$username$ | ....  &amp;lt;/searchString&amp;gt;
            &amp;lt;earliestTime/&amp;gt;
            &amp;lt;latestTime/&amp;gt;
          &amp;lt;/event&amp;gt;
      &amp;lt;/panel&amp;gt;
  &amp;lt;/row&amp;gt;
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Tue, 31 Mar 2015 19:21:07 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Dashboard-drop-down-and-input-option/m-p/123789#M33443</guid>
      <dc:creator>Patient</dc:creator>
      <dc:date>2015-03-31T19:21:07Z</dc:date>
    </item>
    <item>
      <title>Re: Dashboard drop down and input option</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Dashboard-drop-down-and-input-option/m-p/123790#M33444</link>
      <description>&lt;P&gt;Hi sushmitha,&lt;BR /&gt;
In your dashbaord, edit panel and add dropdown input type. Click on pen who is on input that you added.&lt;/P&gt;

&lt;P&gt;To configure it, see the Splunk viz manual where you are going to see, Follow the link &lt;BR /&gt;
&lt;A href="http://docs.splunk.com/Documentation/Splunk/latest/Viz/Aboutthismanual"&gt;http://docs.splunk.com/Documentation/Splunk/latest/Viz/Aboutthismanual&lt;/A&gt;&lt;/P&gt;

&lt;P&gt;You will see all diffferents types of input form configuratioons.&lt;/P&gt;

&lt;P&gt;This is an example:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt; &amp;lt;input type="dropdown" token="user"&amp;gt;
    &amp;lt;label&amp;gt;Select User&amp;lt;/label&amp;gt;
    &amp;lt;populatingSearch fieldForLabel="user" fieldForValue="user"&amp;gt;index=...|stats count by user&amp;lt;/populatingSearch&amp;gt;
    &amp;lt;default&amp;gt; Default user to see on input&amp;lt;/default&amp;gt;
  &amp;lt;/input&amp;gt;
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;and call the token in your search panel like&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;&amp;lt;panel&amp;gt;
       &amp;lt;title&amp;gt;User panel&amp;lt;/title&amp;gt;
       &amp;lt;table&amp;gt;

         &amp;lt;search&amp;gt;
           &amp;lt;query&amp;gt;index=...  user=$user$|.....&amp;lt;/query&amp;gt;
         &amp;lt;/search&amp;gt;
         &amp;lt;option name="wrap"&amp;gt;true&amp;lt;/option&amp;gt;
         &amp;lt;option name="rowNumbers"&amp;gt;false&amp;lt;/option&amp;gt;
         &amp;lt;option name="dataOverlayMode"&amp;gt;none&amp;lt;/option&amp;gt;
         &amp;lt;option name="drilldown"&amp;gt;cell&amp;lt;/option&amp;gt;
         &amp;lt;option name="count"&amp;gt;10&amp;lt;/option&amp;gt;
       &amp;lt;/table&amp;gt;
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Tue, 31 Mar 2015 19:34:13 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Dashboard-drop-down-and-input-option/m-p/123790#M33444</guid>
      <dc:creator>ngatchasandra</dc:creator>
      <dc:date>2015-03-31T19:34:13Z</dc:date>
    </item>
    <item>
      <title>Re: Dashboard drop down and input option</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Dashboard-drop-down-and-input-option/m-p/123791#M33445</link>
      <description>&lt;P&gt;It worked... &lt;BR /&gt;
Thanks... &lt;/P&gt;</description>
      <pubDate>Tue, 31 Mar 2015 20:10:26 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Dashboard-drop-down-and-input-option/m-p/123791#M33445</guid>
      <dc:creator>sushmitha_mj</dc:creator>
      <dc:date>2015-03-31T20:10:26Z</dc:date>
    </item>
    <item>
      <title>Re: Dashboard drop down and input option</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Dashboard-drop-down-and-input-option/m-p/123792#M33446</link>
      <description>&lt;P&gt;It worked... &lt;BR /&gt;
Thanks... &lt;/P&gt;</description>
      <pubDate>Tue, 31 Mar 2015 20:10:43 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Dashboard-drop-down-and-input-option/m-p/123792#M33446</guid>
      <dc:creator>sushmitha_mj</dc:creator>
      <dc:date>2015-03-31T20:10:43Z</dc:date>
    </item>
    <item>
      <title>Re: Dashboard drop down and input option</title>
      <link>https://community.splunk.com/t5/Splunk-Search/Dashboard-drop-down-and-input-option/m-p/123793#M33447</link>
      <description>&lt;P&gt;Thank you for your vote!&lt;/P&gt;</description>
      <pubDate>Tue, 31 Mar 2015 20:17:43 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Search/Dashboard-drop-down-and-input-option/m-p/123793#M33447</guid>
      <dc:creator>Patient</dc:creator>
      <dc:date>2015-03-31T20:17:43Z</dc:date>
    </item>
  </channel>
</rss>

