Splunk Search

Dynamic Table Issue

ringbbg
Engager

HI All. I have a simple dashboard where the data in the statistic table changes everytime you change the dropdown input.
The problem is it only works the first time its loaded, for example, on what is set as default. When I change the dropdown entry, instead of displaying the new table, it displays a random table with random fields...can someone please help?
Below is the code:

  <label>Alarms</label>
  <choice value="1">No Data</choice>
  <choice value="2">Connection Refused</choice>
  <choice value="3">Missing Sequence</choice>
  <choice value="4">Remote Disconnect</choice>
  <default>Connection Refused</default>
  <change>
    <condition value="1">
      <set token="alarms">drqs EXCHANGE sourcetype = ntwkserv "NO DATA" _raw!=*disconnect* |  rex field=_raw "(?<PARSER>\D\FIFW\s\w+\s\w+\s.+\DGO\D\D)" max_match=0 | table _time, PARSER,FE_MACHINE,ERROR,Ticket | sort 0 -_time</set>
    </condition>
    <condition value="2">
      <set token="alarms">drqs EXCHANGE sourcetype = ntwkserv TCPReceiver *refused* | rex field=_raw "(?<PARSER>\D\FIFW\s\w+\s\w+\s.+\DGO\D\D)" max_match=0 | table _time, PARSER, MACHINE,ISSUE,iP,pORT,Ticket | sort 0 -_time</set>
    </condition>
    <condition value="3">
      <set token="alarms">drqs EXCHANGE sourcetype = ntwkserv missing _raw!=*refresh* | rex field=_raw "(?<PARSER>\D\FIFW\s\w+\s\w+\s.+\DGO\D\D)" max_match=0 | table _time, PARSER, MACHINE, error, Ticket | sort 0 -_time</set>
    </condition>
    <condition value="4">
      <set token="alarms">drqs EXCHANGE sourcetype = ntwkserv TCPReceiver *Remote* | rex field=_raw "(?<PARSER>\D\FIFW\s\w+\s\w+\s.+\DGO\D\D)" max_match=0 | table _time, PARSER, MACHINE,ISSUE,iP,pORT,Ticket | sort 0 -_time</set>
    </condition>
  </change>
</input>



<panel>
  <table token="alarms">
    <search>
      <query>$alarms$</query>
      <earliest>$field6.earliest$</earliest>
      <latest>$field6.latest$</latest>
    </search>
    <option name="wrap">undefined</option>
    <option name="rowNumbers">undefined</option>
    <option name="drilldown">row</option>
    <option name="dataOverlayMode">none</option>
    <option name="count">20</option>
  </table>
</panel>
0 Karma

DalJeanis
Legend

@ringbbg -

What, specifically, do you mean by "random"? Is it one of the four, or something else?

Ah.

Your table token matches the token you use in your query. That may be confusing matters - using your first output as the second query.

I'd suggest that you change the table token.

0 Karma
Get Updates on the Splunk Community!

AI for AppInspect

We’re excited to announce two new updates to AppInspect designed to save you time and make the app approval ...

App Platform's 2025 Year in Review: A Year of Innovation, Growth, and Community

As we step into 2026, it’s the perfect moment to reflect on what an extraordinary year 2025 was for the Splunk ...

Operationalizing Entity Risk Score with Enterprise Security 8.3+

Overview Enterprise Security 8.3 introduces a powerful new feature called “Entity Risk Scoring” (ERS) for ...