how to write this if statement with table value and parameter_value

I have the following two statements 

dimension: test1 {
type: number
sql: {% if ${event} = "ABC" and ${event1} = "ABC" %} then 1
{% else %} 0
{% endif %};;

dimension: test2 {
type: number
sql:{% if reservation_param._parameter_value == "123" and reservation_param._parameter_value1 == "123"%}  1
{% else %} 0
{% endif %};;

 

however, If I mix the parameter value with a table value, I keep getting an error. how can you mix parameter_value with table values?

 

dimension: test2 {
type: number
sql:{% if reservation_param._parameter_value == "123" and ${event} = "ABC" %}  1
{% else %} 0
{% endif %};;

 

 

BrianLewis_0-1726077200614.png

 

 

0 1 145
1 REPLY 1
Top Labels in this Space
Top Solution Authors