Getting Data In

input output does not update

jiaqya
Builder

i have created an input drop down which gets a count of a column from a index.
when i change the tokens , i find that the input has that value , but it does not replace the existing previous value , instead it shows up under the input dropdown.

the token test_number shows a value ex: 10
then when i change the token value to look for a new param, it should get me the value 20 for example.

then the token shows 10 on top and 20 on the drop down, it does not show me 20... which should actually be on top based on the new token selection.

any idea how to make this to replace the previous value so it shows on top..

Tags (1)
0 Karma
1 Solution

jiaqya
Builder

Found solution to this from a previous case.. The issue here was that a value was being returned by the input query , but that was not being accepted by default, it was always accepting a previously selected value.
the below solution would ensure the queried value shows up on top as we are converting the output as a token. I believe this should work with other types apart from radio.. hopefully this helps someone..

Below is the exact query that worked. ( removed < from the query, do add it later )

 <input type="radio" token="clnt_number" searchWhenChanged="true" depends="$justHideMe$">
    <label>clnt_number</label>
    <search>
      <query>testquery as clnt_number</query>
      <progress>
                <set token="tokCurrentMonthYear">$result.clnt_number$</set>
        </progress> 
    </search>
    <fieldForLabel>clnt_number</fieldForLabel>
    <fieldForValue>clnt_number</fieldForValue>
    <default>$tokCurrentMonthYear$</default>
  </input>

View solution in original post

0 Karma

jiaqya
Builder

Found solution to this from a previous case.. The issue here was that a value was being returned by the input query , but that was not being accepted by default, it was always accepting a previously selected value.
the below solution would ensure the queried value shows up on top as we are converting the output as a token. I believe this should work with other types apart from radio.. hopefully this helps someone..

Below is the exact query that worked. ( removed < from the query, do add it later )

 <input type="radio" token="clnt_number" searchWhenChanged="true" depends="$justHideMe$">
    <label>clnt_number</label>
    <search>
      <query>testquery as clnt_number</query>
      <progress>
                <set token="tokCurrentMonthYear">$result.clnt_number$</set>
        </progress> 
    </search>
    <fieldForLabel>clnt_number</fieldForLabel>
    <fieldForValue>clnt_number</fieldForValue>
    <default>$tokCurrentMonthYear$</default>
  </input>
0 Karma
Get Updates on the Splunk Community!

Index This | I am a number, but when you add ‘G’ to me, I go away. What number am I?

March 2024 Edition Hayyy Splunk Education Enthusiasts and the Eternally Curious!  We’re back with another ...

What’s New in Splunk App for PCI Compliance 5.3.1?

The Splunk App for PCI Compliance allows customers to extend the power of their existing Splunk solution with ...

Extending Observability Content to Splunk Cloud

Register to join us !   In this Extending Observability Content to Splunk Cloud Tech Talk, you'll see how to ...