I'm new with canvas expression language, so probably my question is trivial: I'm trying to dinamically render an image in a canvas using switch statement, but I've got this error:
Here my code:
filters
| essql query="SELECT value FROM \"dummydata\" as Value ORDER BY timestamp DESC LIMIT 1"
| math "value"
| revealImage origin="bottom" image={asset
| switch
{case if={compare eq to=1} then="asset-408ac6c1-42d8-4ce5-87f3-7bf90bc26a6d"}
{case if={compare eq to=0} then="asset-3812f249-cefe-4c90-9568-6d61477b7293"}
default="asset-df5a0609-c5fa-4c3e-bc2e-d539b38749a8"
}
emptyImage={asset
| switch
{case if={compare eq to=1} then="asset-408ac6c1-42d8-4ce5-87f3-7bf90bc26a6d"}
{case if={compare eq to=0} then="asset-3812f249-cefe-4c90-9568-6d61477b7293"}
default="asset-df5a0609-c5fa-4c3e-bc2e-d539b38749a8"
}
| render
Apache, Apache Lucene, Apache Hadoop, Hadoop, HDFS and the yellow elephant
logo are trademarks of the
Apache Software Foundation
in the United States and/or other countries.