Hello, I am trying to hide or show a panel depending on a search result. I have this search sourcetype=linux_secure user=smith eventtype="ssh_open" OR eventtype="ssh_close" | eval Date=strftime(_time, "%Y-%m-%d %H:%M:%S") | eval UserAction=case(eventtype="ssh_open","On",eventtype="ssh_close","Off",1==1,UserAction) | stats last(UserAction) by Date,host,user | sort - Date | where 'last(UserAction)' == "Off" OR 'last(UserAction)' == "On" the search returns "On" or "Off" as the last "UserAction" I have two panels, panel1 and panel2 If the search in panel1 gives "On" for the result for user "smith", I want to show panel2 then "smith" logs off... then if I rerun the search in panel1 and it returns UserAction == "Off" I want to hide panel2 So far no luck in understanding match for the search result or eval for the search result Here is my logic: <table> <search id="log_action"> <query>sourcetype=linux_secure user=holzapfele eventtype="ssh_open" OR eventtype="ssh_close" | eval Date=strftime(_time, "%Y-%m-%d %H:%M:%S") | eval UserAction=case(eventtype="ssh_open","On",eventtype="ssh_close","Off",1==1,UserAction) | stats last(UserAction) by Date,host,user | sort - Date | where 'last(UserAction)' == "Off" OR 'last(UserAction)' == "On" </query> <earliest>-15m@m</earliest> <latest>now</latest> <sampleRatio>1</sampleRatio> <progress> <condition match="$result.last(UserAction)$==Off"> <set token="hide_panel">true</set> <unset token="hide_panel"></unset> </condition> <condition match="$result.last(UserAction)$==On"> <set token="hide_panel">false</set> <unset token="hide_panel"></unset> </condition> </progress> </search> <option name="count">20</option> <option name="dataOverlayMode">none</option> <option name="drilldown">none</option> <option name="percentagesRow">false</option> <option name="rowNumbers">false</option> <option name="totalsRow">false</option> <option name="wrap">true</option> </table> I am not desiring to use any inputs here for a form, like drop downs, etc I do know I am not understanding the use of the SimpleXML tags, etc. like <done> or result vs. job, etc any suggestions will help, Thanks Again, eholz1
... View more