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!

2024 Splunk Career Impact Survey | Earn a $20 gift card for participating!

Hear ye, hear ye! The time has come again for Splunk's annual Career Impact Survey!  We need your help by ...

Optimize Cloud Monitoring

  TECH TALKS Optimize Cloud Monitoring Tuesday, August 13, 2024  |  11:00AM–12:00PM PST   Register to ...

What's New in Splunk Cloud Platform 9.2.2403?

Hi Splunky people! We are excited to share the newest updates in Splunk Cloud Platform 9.2.2403! Analysts can ...