Dashboards & Visualizations

Dynamic dropdown for a dashboard issue: "Error in 'search' command: Unable to parse the search

brajaram
Communicator

Hi, I'm trying my first attempt at building a dynamic dropdown for a dashboard, and I'm having an issue with the input.

I've set up the dynamic inputs appropriately, as I see the dropdown menu correctly on the dashboard overall. All the possible dropdown options are the exact values I want.

However, when I try to populate the dashboard with the appropriate panel, it gives me the error "Error in 'search' command: Unable to parse the search: Comparator '=' is missing a term on the right hand side.

My search looks as follows: index=<> sourcetype=<> pageURL!="" pageURL=<"URL"> | stats count by source

Doing this search populates the results in the manner I want it to, assuming the URL I put into pageURL is accurate. However, when I replace pageURL with the field '$Page_URL$', which is the name of the dynamic input, it throws that error.

If I instead use pageURL="$Page_URL$" the comparator error is not thrown, but the dashboard panel fails to update to any value and is blank.

0 Karma
1 Solution

mayurr98
Super Champion

How are you passing the input
Through filters?

Then you need to depend your token on that token
You this link to depend on input filter
https://docs.splunk.com/Documentation/Splunk/6.6.3/Viz/tokens
Also refer

https://answers.splunk.com/answers/188709/how-to-display-dashboard-panels-dynamically.html

View solution in original post

mayurr98
Super Champion

How are you passing the input
Through filters?

Then you need to depend your token on that token
You this link to depend on input filter
https://docs.splunk.com/Documentation/Splunk/6.6.3/Viz/tokens
Also refer

https://answers.splunk.com/answers/188709/how-to-display-dashboard-panels-dynamically.html

brajaram
Communicator

I was just passing a simple filter. I created a filter by first creating a new dashboard, and then selecting new input(dropdown). I went through that and created a search query for a table of values that I want to populate the filter with. It seems to be working as intended, as the dropdown filter has all the appropriate selections.

I then clicked on new panel, and tried to write the query I posted above using the token name.

The documentation you referred me to has helped, however...thanks for linking that. Its working(ish) now in that I can populate results. Thanks!

mayurr98
Super Champion

Let me know if it works!

0 Karma
Get Updates on the Splunk Community!

Splunk Enterprise Security 8.x: The Essential Upgrade for Threat Detection, ...

 Prepare to elevate your security operations with the powerful upgrade to Splunk Enterprise Security 8.x! This ...

Get Early Access to AI Playbook Authoring: Apply for the Alpha Private Preview ...

Passionate about security automation? Apply now to our AI Playbook Authoring Alpha private preview ...

Reduce and Transform Your Firewall Data with Splunk Data Management

Managing high-volume firewall data has always been a challenge. Noisy events and verbose traffic logs often ...