Dashboards & Visualizations

How to improve the filter input?

maayan
Path Finder

Hi,

I implemented an input filter, but i want to improve it.
Customers want to select multiple values from the filter and then select more values. in the current situation they need to select 'All ' and then select the values again (each time they want to add values they need to select All-->select values-->remove All)
in addition, they want to select all values except one value, which currently takes time to do.

Is there a smarter filter input in Splunk?


my code:

<input type="multiselect" token="WinTimeStamp" searchWhenChanged="true">
<label>Time</label>
<choice value="%">All</choice>
<default>%</default>
<prefix>(</prefix>
<suffix>)</suffix>
<valuePrefix>(WinTimeStamp like("</valuePrefix>
<valueSuffix>"))</valueSuffix>
<delimiter> OR </delimiter>
<fieldForLabel>WinTimeStamp</fieldForLabel>
<fieldForValue>WinTimeStamp</fieldForValue>
<search>
<query> | where $Name$ 
| dedup WinTimeStamp
| sort WinTimeStamp</query>
</search>
</input>



Thanks,

Maayan

Labels (1)
0 Karma
1 Solution

bharathkumarnec
Contributor

@maayan I would assume if you open the dashboard and there are three dots to the top right corner, if you click there you will see an option to clone in dashboard studio..

View solution in original post

bharathkumarnec
Contributor

@maayan Please check multiselect input using Splunk Dashboard Studio
https://docs.splunk.com/Documentation/Splunk/latest/DashStudio/inputMulti

0 Karma

maayan
Path Finder

how to change my code to something like the filter in the image? 

maayan_0-1699956245686.png

https://docs.splunk.com/Documentation/Splunk/9.1.1/DashStudio/inputMulti

0 Karma

bharathkumarnec
Contributor

@maayan clone the classic dashboard to dashboard studio?

0 Karma

maayan
Path Finder

how can i convert classic dashboard type to studio? 

0 Karma

bharathkumarnec
Contributor

@maayan I would assume if you open the dashboard and there are three dots to the top right corner, if you click there you will see an option to clone in dashboard studio..

maayan
Path Finder

nice idea

the conversation doesn't really works but it's a nice direction!

Anyway, the filter doesn't work. the error (studio) :"Cannot convert undefined or null to object"

code:

{
    "options": {
        "items": [
            {
                "label""All",
                "value""*"
            }
        ],
        "defaultValue""*",
        "token""WinTimeStamp"
    },
    "title""Multiselect Input Title",
    "type""input.multiselect",
    "dataSources": {
        "primary""ds_ICA_General"
    }
}


classic studio code:
<input type="multiselect" token="WinTimeStamp" searchWhenChanged="true">
<label>Time</label>
<choice value="%">All</choice>
<default>%</default>
<prefix>(</prefix>
<suffix>)</suffix>
<valuePrefix>(WinTimeStamp like("</valuePrefix>
<valueSuffix>"))</valueSuffix>
<delimiter> OR </delimiter>
<fieldForLabel>WinTimeStamp</fieldForLabel>
<fieldForValue>WinTimeStamp</fieldForValue>
<search base="ICA_General">
<query> 
| stats values(WinTimeStamp) as WinTimeStamp_
| sort WinTimeStamp_</query>
</search>
</input>
0 Karma
Get Updates on the Splunk Community!

Enter the Dashboard Challenge and Watch the .conf24 Global Broadcast!

The Splunk Community Dashboard Challenge is still happening, and it's not too late to enter for the week of ...

Join Us at the Builder Bar at .conf24 – Empowering Innovation and Collaboration

What is the Builder Bar? The Builder Bar is more than just a place; it's a hub of creativity, collaboration, ...

Combine Multiline Logs into a Single Event with SOCK - a Guide for Advanced Users

This article is the continuation of the “Combine multiline logs into a single event with SOCK - a step-by-step ...