How to pass the value of filter group, in the canvas expression editor

I have created a dropdown in canvas workpad, having values of company.name field. The name of the filterGroup is customerGroup

Lets say the values in the dropdown are: "xyz" and "ABC"

I want to show the asset only if the company name, that I get from the query level is equal to the one that I have selected in the dropdown.

I am trying to achieve that using the below expression

The expression is :

filters
| essql 
  query="SELECT * FROM \"xyz-prod-logs\" WHERE \"@timestamp\" > NOW() - INTERVAL 2 MONTH  and \"@timestamp\" < NOW() - INTERVAL 1 MONTH ORDER BY \"@timestamp\""
| mapColumn "markdown_content" 
  fn={getCell "company.name" | if {compare "eq" to={filters group="customerGroup"}} then={string "[![](" {asset "asset-3d0ad912-1b2f-460f-a463-d23ef9a7062f"} ")]"} else=""}
| markdown {getCell "markdown_content"}
| render

In the above expression if I replace {filters group="customerGroup"} to "xyz", then the expression is working correctly.

How can I pass the selected value of dropdown, in the canvas expression editor ?

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.