Transform Map Expression Not working properly

Can anyone help me here? Wasn't this supposed to return red instead of black?

Naive suggestion: should it be {value}["running"]==true?

There might be an underlying issue with extracting values from an expression structure in a map transform, I'm not sure...

But either way, this seems like a bad structural choice.
If the states are mutually exclusive (surely stopped is the inverse of running) then you only need one boolean.
If you truly want to represent all possible states of the two booleans aggregated, then use an expression (not an expression structure) binding and the binEnc function, so that you can represent an actual truth table - two bits makes four possible states.

Thanks Leor, but it didnt work.

1 Like

Yeah, I know.
I'm doing it differently, this is just an example.
I liked the binEnc idea, I'll try that. Thank you!

1 Like