Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Optional dropdown Parameter in Azure workbook

Tags:

kql

I want to create an optional dropdown parameter in an Azure Workbook. Creating a dropdown parameter with this guide is straight forward

Then the parameter can be referenced in KQL as shown in the example with

 requests
    | where name == '{RequestName}'

So far so good, I now want this parameter to be optional and if a value is not selected in the dropdown to get all the results unfiltered, like I would get if the |where part was not there at all. Right now if this parameter is not set then I get a Query could not be parsed error.

Is this possible?

like image 298
ltsallas Avatar asked Feb 24 '26 21:02

ltsallas


1 Answers

requests
| where isempty('{RequestName}') or (name == '{RequestName}')
like image 174
Slavik N Avatar answered Feb 26 '26 23:02

Slavik N



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!