Dashboards & Visualizations

How could I check multiple condition(state) at <input> token?

Questioner
Path Finder

I want to combine these two <condition> into one.

<input>
.....
<change>
<condition value = "BT">
<unset token="show_wifi_connect_type"></unset>
</condition>
<condition value="UART">
<unset token="show_wifi_connect_type"></unset>
</condition>
</change>
...
</input>

I tried combine these two status using "match", but it doesn't work.
How could I solve this problem?

Labels (1)
Tags (2)
0 Karma
1 Solution

dtburrows3
Builder

I believe this should do it.

<input>
.....
  <change>
    <condition match="'value'==&quot;BT&quot; OR 'value'==&quot;UART&quot;">
        <unset token="show_wifi_connect_type"></unset>
    </condition>
   </change>
...
</input>

 
You can see on the screenshots it worked as expected when testing locally.

dtburrows3_0-1703773137637.png

dtburrows3_1-1703773155945.png

dtburrows3_2-1703773171653.png

 

View solution in original post

Questioner
Path Finder

@dtburrows3  Thank you for your support!

It work!

0 Karma

dtburrows3
Builder

I believe this should do it.

<input>
.....
  <change>
    <condition match="'value'==&quot;BT&quot; OR 'value'==&quot;UART&quot;">
        <unset token="show_wifi_connect_type"></unset>
    </condition>
   </change>
...
</input>

 
You can see on the screenshots it worked as expected when testing locally.

dtburrows3_0-1703773137637.png

dtburrows3_1-1703773155945.png

dtburrows3_2-1703773171653.png

 

Career Survey
First 500 qualified respondents will receive a $20 gift card! Tell us about your professional Splunk journey.

Can’t make it to .conf25? Join us online!

Get Updates on the Splunk Community!

What Is Splunk? Here’s What You Can Do with Splunk

Hey Splunk Community, we know you know Splunk. You likely leverage its unparalleled ability to ingest, index, ...

Level Up Your .conf25: Splunk Arcade Comes to Boston

With .conf25 right around the corner in Boston, there’s a lot to look forward to — inspiring keynotes, ...

Manual Instrumentation with Splunk Observability Cloud: How to Instrument Frontend ...

Although it might seem daunting, as we’ve seen in this series, manual instrumentation can be straightforward ...