I have a question about the dynamic query in the drop-down list options. I am getting an error "Duplicate values causing conflict" and when I open the UI of the drop-down list, in the token options, it says the "Duplicate values causing conflict" for the default and the initial value fields. I am not sure of why it is asking those values for a dynamic query. Can someone please suggest on how to overcome this problem?
I suggest that you edit the dashboard and edit the input. In the UI, you will see a setting for both the default value and the initial value. You do not need both of these. I would remove any setting in the initial value field, then save everything.
This should solve the problem, if these are the only duplicates.
Just for reference:
In fact removing these two settings (defaultValue and initalValue) have no effect on the problem.
The real solution I found here.
Actually "fieldForValue" is the key field: if this field is not in the search filling the dropdown/multiselect-box it is empty for every row (e.g. picked from a lookup file). And if you pick five rows form a lookup file you have five times the "empty" value, which obviously is duplicate. If your input just has one row, there's no duplicate - but - the box stays emtpy as the fieldForValue-key is still missing in your input.
I have cleared the selection for both the initial value and the default token options, but it still is giving the "Duplicate values causing conflict" message for both of those options. For a dynamic query, how would it determine the output without executing it. Is it persisting the output of the previous run?
Here is the query I am using:
index=64581-cli sourcetype=show_version | eval hi= split(hostname, ".") | eval hi2=mvindex(hi, 3) | dedup hi2 | stats count by hi2
Thanks and please suggest.
Whatever your query is, to remove duplications, simply add "| dedup [field_value]" to your search for that dropdown. As long as the time span for that dynamic search and your overall dashboard display's search are the same, you shouldn't come up with any missing/unexpected values.