Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Qlik and ServiceNow Partner to Bring Trusted Enterprise Context into AI-Powered Workflows. Learn More!
cancel
Showing results for 
Search instead for 
Did you mean: 
bensomers
Contributor II
Contributor II

How to add colour to expression?

Hi experts,

Can anyone tell me how to adjust the below expression so that 'Pass' is green and 'Fail' is red?

=IF(Count({<SLAMet= {'Yes'}>} SLAMet)/Count(SLAMet)>.98,'Pass','Fail')

Thanks!

10 Replies
dwforest
Specialist II
Specialist II

Try using a dual()

instead of returning Pass / Fail, dual('Pass',1) / dual('Fail'),0)

In theory it will display the text but have the number for calculations just like dates