<?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 dashboard with a drop-down populated with extracted field headers from a CSV file? in Dashboards &amp; Visualizations</title>
    <link>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-create-a-dashboard-with-a-drop-down-populated-with/m-p/169304#M10421</link>
    <description>&lt;P&gt;Where do i keep this XMLs? please explain in detail&lt;/P&gt;</description>
    <pubDate>Mon, 21 Nov 2016 08:17:50 GMT</pubDate>
    <dc:creator>saura1312</dc:creator>
    <dc:date>2016-11-21T08:17:50Z</dc:date>
    <item>
      <title>How to create a dashboard with a drop-down populated with extracted field headers from a CSV file?</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-create-a-dashboard-with-a-drop-down-populated-with/m-p/169297#M10414</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;

&lt;P&gt;I have imported a CSV file which has auto extracted the column heading and values &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;  The task I have now is to create a dashboard where the user can select the time period (done) and then select the the field header they are interested in.  Is this possible and how do I get the extracted headers into the drop-down?&lt;/P&gt;

&lt;P&gt;Cheers&lt;/P&gt;</description>
      <pubDate>Thu, 05 Mar 2015 11:52:15 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-create-a-dashboard-with-a-drop-down-populated-with/m-p/169297#M10414</guid>
      <dc:creator>cdstealer</dc:creator>
      <dc:date>2015-03-05T11:52:15Z</dc:date>
    </item>
    <item>
      <title>Re: How to create a dashboard with a drop-down populated with extracted field headers from a CSV file?</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-create-a-dashboard-with-a-drop-down-populated-with/m-p/169298#M10415</link>
      <description>&lt;P&gt;Seems like you will want to setup a Form with with dropdown fieldset:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;&amp;lt;form&amp;gt;
  &amp;lt;fieldset&amp;gt;
    &amp;lt;input type="dropdown"&amp;gt;
      &amp;lt;search&amp;gt;
        &amp;lt;query&amp;gt;source=csv | fields field1,field2&amp;lt;/query&amp;gt;
      &amp;lt;/search&amp;gt;
    &amp;lt;/input&amp;gt;
  &amp;lt;/fieldset&amp;gt;
&amp;lt;/form&amp;gt;
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Something like this will populate a dropdown with the results from the search you specify.&lt;/P&gt;</description>
      <pubDate>Sat, 07 Mar 2015 02:32:52 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-create-a-dashboard-with-a-drop-down-populated-with/m-p/169298#M10415</guid>
      <dc:creator>muebel</dc:creator>
      <dc:date>2015-03-07T02:32:52Z</dc:date>
    </item>
    <item>
      <title>Re: How to create a dashboard with a drop-down populated with extracted field headers from a CSV file?</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-create-a-dashboard-with-a-drop-down-populated-with/m-p/169299#M10416</link>
      <description>&lt;P&gt;Hi Muebel,&lt;BR /&gt;
Thanks for the reply.. unfortunately I've already done that (kind of).. Specifying individual fields is not realistic due to the amount of them.  The query I used is &lt;STRONG&gt;index=storage_csv sourcetype=storage_csv | fields "CLASS*"&lt;/STRONG&gt; but it complains of "duplicate labels" of which there are none.  This is a very basic XML that I've used:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;&amp;lt;form&amp;gt;
  &amp;lt;fieldset&amp;gt;
    &amp;lt;input type="time" token="field1"&amp;gt;
      &amp;lt;label&amp;gt;&amp;lt;/label&amp;gt;
      &amp;lt;default&amp;gt;
        &amp;lt;earliest&amp;gt;0&amp;lt;/earliest&amp;gt;
        &amp;lt;latest&amp;gt;&amp;lt;/latest&amp;gt;
      &amp;lt;/default&amp;gt;
    &amp;lt;/input&amp;gt;
    &amp;lt;input type="dropdown"&amp;gt;
      &amp;lt;search&amp;gt;
        &amp;lt;query&amp;gt;index=storage_csv sourcetype=storage_csv | fields "CLASS*"&amp;lt;/query&amp;gt;
          &amp;lt;earliest&amp;gt;$field1.earliest$&amp;lt;/earliest&amp;gt;
          &amp;lt;latest&amp;gt;$field1.latest$&amp;lt;/latest&amp;gt;
      &amp;lt;/search&amp;gt;
    &amp;lt;/input&amp;gt;
  &amp;lt;/fieldset&amp;gt;
&amp;lt;/form&amp;gt;
&lt;/CODE&gt;&lt;/PRE&gt;

&lt;P&gt;Running the query manually returns the fields as expected.&lt;/P&gt;</description>
      <pubDate>Mon, 28 Sep 2020 19:06:03 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-create-a-dashboard-with-a-drop-down-populated-with/m-p/169299#M10416</guid>
      <dc:creator>cdstealer</dc:creator>
      <dc:date>2020-09-28T19:06:03Z</dc:date>
    </item>
    <item>
      <title>Re: How to create a dashboard with a drop-down populated with extracted field headers from a CSV file?</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-create-a-dashboard-with-a-drop-down-populated-with/m-p/169300#M10417</link>
      <description>&lt;P&gt;Ah, I left a bit out. You will need to add a couple more elements to the dropdown input:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;  &amp;lt;fieldForLabel&amp;gt;CLASS&amp;lt;/fieldForLabel&amp;gt;
  &amp;lt;fieldForValue&amp;gt;CLASS&amp;lt;/fieldForValue&amp;gt;
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Sat, 07 Mar 2015 09:14:04 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-create-a-dashboard-with-a-drop-down-populated-with/m-p/169300#M10417</guid>
      <dc:creator>muebel</dc:creator>
      <dc:date>2015-03-07T09:14:04Z</dc:date>
    </item>
    <item>
      <title>Re: How to create a dashboard with a drop-down populated with extracted field headers from a CSV file?</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-create-a-dashboard-with-a-drop-down-populated-with/m-p/169301#M10418</link>
      <description>&lt;P&gt;Hi Muebel,&lt;BR /&gt;
Thanks again.. unfortunately I still get the "Duplicate labels" error.  I ran the query &lt;STRONG&gt;index=storage_csv sourcetype=storage_csv | transpose | rename column as class | sort -class&lt;/STRONG&gt; to ensure there were no duplicates being returned.  Which of course there aren't.  I am utterly stuck on this one &lt;span class="lia-unicode-emoji" title=":disappointed_face:"&gt;😞&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 28 Sep 2020 19:06:06 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-create-a-dashboard-with-a-drop-down-populated-with/m-p/169301#M10418</guid>
      <dc:creator>cdstealer</dc:creator>
      <dc:date>2020-09-28T19:06:06Z</dc:date>
    </item>
    <item>
      <title>Re: How to create a dashboard with a drop-down populated with extracted field headers from a CSV file?</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-create-a-dashboard-with-a-drop-down-populated-with/m-p/169302#M10419</link>
      <description>&lt;P&gt;You just want the CSV header names (e.g. field1, field2) into the dropdown? If yes try below query:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;&amp;lt;form&amp;gt;
   &amp;lt;fieldset&amp;gt;
     &amp;lt;input type="time" token="field1"&amp;gt;
       &amp;lt;label&amp;gt;&amp;lt;/label&amp;gt;
       &amp;lt;default&amp;gt;
         &amp;lt;earliest&amp;gt;0&amp;lt;/earliest&amp;gt;
         &amp;lt;latest&amp;gt;&amp;lt;/latest&amp;gt;
       &amp;lt;/default&amp;gt;
     &amp;lt;/input&amp;gt;
     &amp;lt;input type="dropdown"&amp;gt;
       &amp;lt;search&amp;gt;
         &amp;lt;query&amp;gt;index=storage_csv sourcetype=storage_csv | head 1 | transpose | fields column | search column=CLASS* &amp;lt;/query&amp;gt;
           &amp;lt;earliest&amp;gt;$field1.earliest$&amp;lt;/earliest&amp;gt;
           &amp;lt;latest&amp;gt;$field1.latest$&amp;lt;/latest&amp;gt;
       &amp;lt;/search&amp;gt;
&amp;lt;fieldForLabel&amp;gt;column&amp;lt;/fieldForLabel&amp;gt;
   &amp;lt;fieldForValue&amp;gt;column&amp;lt;/fieldForValue&amp;gt;
     &amp;lt;/input&amp;gt;
   &amp;lt;/fieldset&amp;gt;
 &amp;lt;/form&amp;gt;
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Sun, 08 Mar 2015 20:37:52 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-create-a-dashboard-with-a-drop-down-populated-with/m-p/169302#M10419</guid>
      <dc:creator>somesoni2</dc:creator>
      <dc:date>2015-03-08T20:37:52Z</dc:date>
    </item>
    <item>
      <title>Re: How to create a dashboard with a drop-down populated with extracted field headers from a CSV file?</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-create-a-dashboard-with-a-drop-down-populated-with/m-p/169303#M10420</link>
      <description>&lt;P&gt;somesoni2.. you sir, are a life saver!  Thank you very very much &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 09 Mar 2015 07:30:00 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-create-a-dashboard-with-a-drop-down-populated-with/m-p/169303#M10420</guid>
      <dc:creator>cdstealer</dc:creator>
      <dc:date>2015-03-09T07:30:00Z</dc:date>
    </item>
    <item>
      <title>Re: How to create a dashboard with a drop-down populated with extracted field headers from a CSV file?</title>
      <link>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-create-a-dashboard-with-a-drop-down-populated-with/m-p/169304#M10421</link>
      <description>&lt;P&gt;Where do i keep this XMLs? please explain in detail&lt;/P&gt;</description>
      <pubDate>Mon, 21 Nov 2016 08:17:50 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Dashboards-Visualizations/How-to-create-a-dashboard-with-a-drop-down-populated-with/m-p/169304#M10421</guid>
      <dc:creator>saura1312</dc:creator>
      <dc:date>2016-11-21T08:17:50Z</dc:date>
    </item>
  </channel>
</rss>

