<?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: submit button not passing tokens in Splunk Enterprise</title>
    <link>https://community.splunk.com/t5/Splunk-Enterprise/submit-button-not-passing-tokens/m-p/313232#M6770</link>
    <description>&lt;P&gt;This totally defeats the purpose of the &lt;CODE&gt;submit&lt;/CODE&gt; button.&lt;/P&gt;</description>
    <pubDate>Sat, 27 May 2017 07:23:35 GMT</pubDate>
    <dc:creator>woodcock</dc:creator>
    <dc:date>2017-05-27T07:23:35Z</dc:date>
    <item>
      <title>submit button not passing tokens</title>
      <link>https://community.splunk.com/t5/Splunk-Enterprise/submit-button-not-passing-tokens/m-p/313228#M6766</link>
      <description>&lt;P&gt;Hi All&lt;/P&gt;

&lt;P&gt;I am running into some strange behavior(atleast for me) with dashboard submit button&lt;/P&gt;

&lt;P&gt;Dashboard has &lt;BR /&gt;
   time picker&lt;BR /&gt;
   1 textbox input [which takes comma separated order numbers]&lt;BR /&gt;
    Submit button&lt;/P&gt;

&lt;P&gt;My usecase is to allow the Support teams look up customer details using order numbers[they can enter any number of orders 1 or 10 or 100 or 1000 all , seperated], output gives customer name,custmer email,order number.&lt;/P&gt;

&lt;P&gt;When i choose the time , key in say 2 order numbers and hit submit button ...my panel searches are not triggered as the tokens are not passed on to panels(i am displaying tokens in panel titles), however when i click the cross max on the text box to remove the value and click anywhere on dashboard[i am not clicking submit button] the tokens are being passed and the panels work. In short submit button does not seem to work.&lt;/P&gt;

&lt;P&gt;Any idea why this behavior is happening and how it can be corrected.&lt;/P&gt;

&lt;P&gt;&lt;STRONG&gt;Example:&lt;/STRONG&gt;&lt;BR /&gt;&lt;BR /&gt;
                  Input=ord123,ord234,ord345&lt;BR /&gt;
                  search becomes --&amp;gt;index=xyz  ord123 OR ord234 OR ord345| table orderid,cust_firstname,cust_lastname,cust_email&lt;BR /&gt;
          Label --&amp;gt;Customer Details---ord123 OR ord234 OR ord345&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;&amp;lt;form&amp;gt;
  &amp;lt;label&amp;gt; Customer Details using Order Number&amp;lt;/label&amp;gt;
  &amp;lt;fieldset submitButton="true" autoRun="false"&amp;gt;
    &amp;lt;input type="time" token="time_token" searchWhenChanged="false"&amp;gt;
      &amp;lt;label&amp;gt;Select Time&amp;lt;/label&amp;gt;
      &amp;lt;default&amp;gt;
        &amp;lt;earliest&amp;gt;@d&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;input type="text" token="Orderid_token" searchWhenChanged="false"&amp;gt;
      &amp;lt;label&amp;gt;Enter OrderNumber&amp;lt;/label&amp;gt;
      &amp;lt;change&amp;gt;
        &amp;lt;eval token="Orderid_frmt_token"&amp;gt;replace($Orderid_token$,","," OR ")&amp;lt;/eval&amp;gt;
      &amp;lt;/change&amp;gt;
    &amp;lt;/input&amp;gt;
  &amp;lt;/fieldset&amp;gt; 
  &amp;lt;row&amp;gt;
    &amp;lt;panel&amp;gt;
      &amp;lt;title&amp;gt;Customer Details---$Orderid_frmt_token$&amp;lt;/title&amp;gt;
      &amp;lt;table&amp;gt;
        &amp;lt;search&amp;gt;
          &amp;lt;query&amp;gt;index=xyz  $Orderid_frmt_token$| table orderid,cust_firstname,cust_lastname,cust_email &amp;lt;/query&amp;gt;
          &amp;lt;earliest&amp;gt;$time_token.earliest$&amp;lt;/earliest&amp;gt;
          &amp;lt;latest&amp;gt;$time_token.latest$&amp;lt;/latest&amp;gt;
          &amp;lt;sampleRatio&amp;gt;1&amp;lt;/sampleRatio&amp;gt;
        &amp;lt;/search&amp;gt;
        &amp;lt;option name="count"&amp;gt;100&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="percentagesRow"&amp;gt;false&amp;lt;/option&amp;gt;
        &amp;lt;option name="rowNumbers"&amp;gt;false&amp;lt;/option&amp;gt;
        &amp;lt;option name="totalsRow"&amp;gt;false&amp;lt;/option&amp;gt;
        &amp;lt;option name="wrap"&amp;gt;true&amp;lt;/option&amp;gt;
      &amp;lt;/table&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>Tue, 29 Sep 2020 14:12:46 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Enterprise/submit-button-not-passing-tokens/m-p/313228#M6766</guid>
      <dc:creator>newbie2tech</dc:creator>
      <dc:date>2020-09-29T14:12:46Z</dc:date>
    </item>
    <item>
      <title>Re: submit button not passing tokens</title>
      <link>https://community.splunk.com/t5/Splunk-Enterprise/submit-button-not-passing-tokens/m-p/313229#M6767</link>
      <description>&lt;P&gt;Since you are setting the token on change event of the Text box you should turn on &lt;CODE&gt;searchWhenChanged="true"&lt;/CODE&gt; for the same.&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;&amp;lt;input type="text" token="Orderid_token" searchWhenChanged="true"&amp;gt;
  &amp;lt;label&amp;gt;Enter OrderNumber&amp;lt;/label&amp;gt;
  &amp;lt;change&amp;gt;
    &amp;lt;eval token="Orderid_frmt_token"&amp;gt;replace($Orderid_token$,","," OR ")&amp;lt;/eval&amp;gt;
  &amp;lt;/change&amp;gt;
&amp;lt;/input&amp;gt;
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Fri, 26 May 2017 21:19:56 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Enterprise/submit-button-not-passing-tokens/m-p/313229#M6767</guid>
      <dc:creator>niketn</dc:creator>
      <dc:date>2017-05-26T21:19:56Z</dc:date>
    </item>
    <item>
      <title>Re: submit button not passing tokens</title>
      <link>https://community.splunk.com/t5/Splunk-Enterprise/submit-button-not-passing-tokens/m-p/313230#M6768</link>
      <description>&lt;P&gt;It looks to me that using &lt;CODE&gt;&amp;lt;eval&amp;gt;&lt;/CODE&gt; like this with the &lt;CODE&gt;submit&lt;/CODE&gt; button is TOTALLY borked and a support case should be opened.  I am sure that your code should be more like this (which causes your incorrectly-working clear-field case to be correctly-nonworking), but it does not really fix much:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;  &amp;lt;change&amp;gt;
    &amp;lt;condition value=""&amp;gt;
      &amp;lt;unset token="Orderid_frmt_token"&amp;gt;&amp;lt;/unset&amp;gt;
    &amp;lt;/condition&amp;gt;
    &amp;lt;condition value="*"&amp;gt;
      &amp;lt;eval token="Orderid_frmt_token"&amp;gt;replace($Orderid_token$,","," OR ")&amp;lt;/eval&amp;gt;
    &amp;lt;/condition&amp;gt;
  &amp;lt;/change&amp;gt;
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Sat, 27 May 2017 06:57:57 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Enterprise/submit-button-not-passing-tokens/m-p/313230#M6768</guid>
      <dc:creator>woodcock</dc:creator>
      <dc:date>2017-05-27T06:57:57Z</dc:date>
    </item>
    <item>
      <title>Re: submit button not passing tokens</title>
      <link>https://community.splunk.com/t5/Splunk-Enterprise/submit-button-not-passing-tokens/m-p/313231#M6769</link>
      <description>&lt;P&gt;OK, let's just bypass the &lt;CODE&gt;&amp;lt;eval&amp;gt;&lt;/CODE&gt; thing altogether and replace with a &lt;CODE&gt;subsearch&lt;/CODE&gt;.  This seems to work just fine:&lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;&amp;lt;form&amp;gt;
  &amp;lt;label&amp;gt;Customer Details using Order Number&amp;lt;/label&amp;gt;
  &amp;lt;fieldset submitButton="true" autoRun="false"&amp;gt;
    &amp;lt;input type="time" token="time_token" searchWhenChanged="false"&amp;gt;
      &amp;lt;label&amp;gt;Select Time&amp;lt;/label&amp;gt;
      &amp;lt;default&amp;gt;
        &amp;lt;earliest&amp;gt;@d&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;input type="text" token="Orderid_token" searchWhenChanged="false"&amp;gt;
      &amp;lt;label&amp;gt;Enter OrderNumber&amp;lt;/label&amp;gt;
      &amp;lt;!--change&amp;gt;
        &amp;lt;condition value=""&amp;gt;
          &amp;lt;unset token="Orderid_frmt_token"&amp;gt;&amp;lt;/unset&amp;gt;
        &amp;lt;/condition&amp;gt;
        &amp;lt;condition value="*"&amp;gt;
          &amp;lt;eval token="Orderid_frmt_token"&amp;gt;replace($Orderid_token$,","," OR ")&amp;lt;/eval&amp;gt;
        &amp;lt;/condition&amp;gt;
      &amp;lt;/change--&amp;gt;
    &amp;lt;/input&amp;gt;
  &amp;lt;/fieldset&amp;gt;
  &amp;lt;row&amp;gt;
    &amp;lt;panel&amp;gt;
      &amp;lt;title&amp;gt;Customer Details---$Orderid_token$&amp;lt;/title&amp;gt;
      &amp;lt;table&amp;gt;
        &amp;lt;search&amp;gt;
          &amp;lt;query&amp;gt;index=_* [| makeresults | eval search=replace("$Orderid_token$",","," OR ") | fields - _time] | stats count BY host source sourcetype index&amp;lt;/query&amp;gt;
          &amp;lt;earliest&amp;gt;$time_token.earliest$&amp;lt;/earliest&amp;gt;
          &amp;lt;latest&amp;gt;$time_token.latest$&amp;lt;/latest&amp;gt;
          &amp;lt;sampleRatio&amp;gt;1&amp;lt;/sampleRatio&amp;gt;
        &amp;lt;/search&amp;gt;
        &amp;lt;option name="count"&amp;gt;100&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="percentagesRow"&amp;gt;false&amp;lt;/option&amp;gt;
        &amp;lt;option name="rowNumbers"&amp;gt;false&amp;lt;/option&amp;gt;
        &amp;lt;option name="totalsRow"&amp;gt;false&amp;lt;/option&amp;gt;
        &amp;lt;option name="wrap"&amp;gt;true&amp;lt;/option&amp;gt;
      &amp;lt;/table&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>Sat, 27 May 2017 07:22:28 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Enterprise/submit-button-not-passing-tokens/m-p/313231#M6769</guid>
      <dc:creator>woodcock</dc:creator>
      <dc:date>2017-05-27T07:22:28Z</dc:date>
    </item>
    <item>
      <title>Re: submit button not passing tokens</title>
      <link>https://community.splunk.com/t5/Splunk-Enterprise/submit-button-not-passing-tokens/m-p/313232#M6770</link>
      <description>&lt;P&gt;This totally defeats the purpose of the &lt;CODE&gt;submit&lt;/CODE&gt; button.&lt;/P&gt;</description>
      <pubDate>Sat, 27 May 2017 07:23:35 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Enterprise/submit-button-not-passing-tokens/m-p/313232#M6770</guid>
      <dc:creator>woodcock</dc:creator>
      <dc:date>2017-05-27T07:23:35Z</dc:date>
    </item>
    <item>
      <title>Re: submit button not passing tokens</title>
      <link>https://community.splunk.com/t5/Splunk-Enterprise/submit-button-not-passing-tokens/m-p/313233#M6771</link>
      <description>&lt;P&gt;Yes I know but my point was that if change event handler has to be coded then searchWhenChanged should be turned on as well. Following is a way Text box can be grouped in the panel with Search so that Submit button applies for Time and Text box remain independent of Submit button. &lt;/P&gt;

&lt;PRE&gt;&lt;CODE&gt;&amp;lt;form&amp;gt;
  &amp;lt;label&amp;gt;Customer Details using Order Number&amp;lt;/label&amp;gt;
  &amp;lt;fieldset submitButton="true" autoRun="false"&amp;gt;
    &amp;lt;input type="time" token="time_token" searchWhenChanged="false"&amp;gt;
      &amp;lt;label&amp;gt;Select Time&amp;lt;/label&amp;gt;
      &amp;lt;default&amp;gt;
        &amp;lt;earliest&amp;gt;@d&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;title&amp;gt;Customer Details---$Orderid_frmt_token$&amp;lt;/title&amp;gt;
      &amp;lt;input type="text" token="Orderid_token" searchWhenChanged="true"&amp;gt;
        &amp;lt;label&amp;gt;Enter OrderNumber&amp;lt;/label&amp;gt;
        &amp;lt;change&amp;gt;
          &amp;lt;eval token="Orderid_frmt_token"&amp;gt;replace($Orderid_token$,","," OR ")&amp;lt;/eval&amp;gt;
        &amp;lt;/change&amp;gt;
      &amp;lt;/input&amp;gt;
       &amp;lt;table&amp;gt;
         &amp;lt;search&amp;gt;
           &amp;lt;query&amp;gt;index=xyz  $Orderid_frmt_token$| table orderid,cust_firstname,cust_lastname,cust_email &amp;lt;/query&amp;gt;
           &amp;lt;earliest&amp;gt;$time_token.earliest$&amp;lt;/earliest&amp;gt;
           &amp;lt;latest&amp;gt;$time_token.latest$&amp;lt;/latest&amp;gt;
           &amp;lt;sampleRatio&amp;gt;1&amp;lt;/sampleRatio&amp;gt;
         &amp;lt;/search&amp;gt;
         &amp;lt;option name="count"&amp;gt;100&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="percentagesRow"&amp;gt;false&amp;lt;/option&amp;gt;
         &amp;lt;option name="rowNumbers"&amp;gt;false&amp;lt;/option&amp;gt;
         &amp;lt;option name="totalsRow"&amp;gt;false&amp;lt;/option&amp;gt;
         &amp;lt;option name="wrap"&amp;gt;true&amp;lt;/option&amp;gt;
       &amp;lt;/table&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>Sat, 27 May 2017 14:37:45 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Enterprise/submit-button-not-passing-tokens/m-p/313233#M6771</guid>
      <dc:creator>niketn</dc:creator>
      <dc:date>2017-05-27T14:37:45Z</dc:date>
    </item>
    <item>
      <title>Re: submit button not passing tokens</title>
      <link>https://community.splunk.com/t5/Splunk-Enterprise/submit-button-not-passing-tokens/m-p/313234#M6772</link>
      <description>&lt;P&gt;Just as an FYI, the &lt;CODE&gt;change&lt;/CODE&gt; handler &lt;CODE&gt;set&lt;/CODE&gt;, &lt;CODE&gt;unset&lt;/CODE&gt;, and &lt;CODE&gt;eval&lt;/CODE&gt; statements always alter the submitted token value, regardless of the &lt;CODE&gt;searchWhenChanged&lt;/CODE&gt; setting. This holds for all input types regardless of the submit button being present or not. This side effect has been the bane of my dashboards in many cases.&lt;/P&gt;</description>
      <pubDate>Sat, 27 May 2017 15:01:59 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Enterprise/submit-button-not-passing-tokens/m-p/313234#M6772</guid>
      <dc:creator>rjthibod</dc:creator>
      <dc:date>2017-05-27T15:01:59Z</dc:date>
    </item>
    <item>
      <title>Re: submit button not passing tokens</title>
      <link>https://community.splunk.com/t5/Splunk-Enterprise/submit-button-not-passing-tokens/m-p/313235#M6773</link>
      <description>&lt;P&gt;Thanks woodcock...this worked like a charm. Wanted to ask will it have any limitations in terms of how many values it can take[like 10000 only?].&lt;/P&gt;</description>
      <pubDate>Tue, 30 May 2017 20:57:40 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Enterprise/submit-button-not-passing-tokens/m-p/313235#M6773</guid>
      <dc:creator>newbie2tech</dc:creator>
      <dc:date>2017-05-30T20:57:40Z</dc:date>
    </item>
    <item>
      <title>Re: submit button not passing tokens</title>
      <link>https://community.splunk.com/t5/Splunk-Enterprise/submit-button-not-passing-tokens/m-p/313236#M6774</link>
      <description>&lt;P&gt;thanks niketnilay... for the first option which you suggested i had tried those combinations before posting the question it did not work and as woodcock mentioned Submit button would have no meaning.&lt;BR /&gt;
2nd suggestion does not work for me as i have 4 panels i cannot input them in each panel.thank you for chiming in.  &lt;/P&gt;

&lt;P&gt;Thanks rjthibod for the information.&lt;/P&gt;</description>
      <pubDate>Tue, 30 May 2017 20:58:52 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Enterprise/submit-button-not-passing-tokens/m-p/313236#M6774</guid>
      <dc:creator>newbie2tech</dc:creator>
      <dc:date>2017-05-30T20:58:52Z</dc:date>
    </item>
    <item>
      <title>Re: submit button not passing tokens</title>
      <link>https://community.splunk.com/t5/Splunk-Enterprise/submit-button-not-passing-tokens/m-p/313237#M6775</link>
      <description>&lt;P&gt;So your workaround (your answer) worked for his use case but doesn't for mine. I need to do something like the above. Any ideas?&lt;/P&gt;

&lt;P&gt;&lt;A href="https://answers.splunk.com/answers/742451/searchwhenchangedfalse-not-honored-1.html"&gt;https://answers.splunk.com/answers/742451/searchwhenchangedfalse-not-honored-1.html&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 24 Apr 2019 21:52:14 GMT</pubDate>
      <guid>https://community.splunk.com/t5/Splunk-Enterprise/submit-button-not-passing-tokens/m-p/313237#M6775</guid>
      <dc:creator>nick405060</dc:creator>
      <dc:date>2019-04-24T21:52:14Z</dc:date>
    </item>
  </channel>
</rss>

