below is my dashboard code, when checkbox is selected i want splunkd* only to be shown in the dropdown else all.
below code seems like is finding checkbox is selected and going to if section , but,sourcetype like "splunkd*" is always evaluating to true/false and also like doesnt seems to work ? any updates?
<query>index=_internal | eval field1= if(replace("$applyFilter$",".*(\d)","\1")="1",sourcetype like "splunkd*", ,sourcetype)</query>
--Sree
<form>
<label>ConditionalFilter1</label>
<fieldset submitButton="false">
<input type="checkbox" token="applyFilter" searchWhenChanged="true">
<label></label>
<choice value="1">Apply Filter</choice>
<default>0</default>
</input>
<inpu't type="dropdown" token="field1" searchWhenChanged="true">'
<search>
<query>index=_internal | eval field1= if(replace("$applyFilter$",".*(\d)","\1")="1",sourcetype,sourcetype)</query>
</search>
<fieldForLabel>field1</fieldForLabel>
<fieldForValue>field1</fieldForValue>
</input>
</fieldset>
</form>
... View more