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

Announcements
Talend Cloud AWS EU Scheduled Outage: Starting Tues 26 May 21:00 CEST with expected completion Wed 27 May 01:00 CEST
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Output a text if a condition is not met

Hi All,

Is it possible for a measure to output a text if a condition is not met?  I have an IF statement for a condition that when satisfied will sum all values otherwise, it should output "N/A".

Thanks!

8 Replies
alexandros17
Partner - Champion III
Partner - Champion III

Use a text box and in "Layout" tab in Show section use conditional with your condition

Not applicable
Author

Thanks for the reply! However, I'm using QlikSense and I can't seem to find the 'layout' tab.

robert_mika

Yes just type

if(sum(Units )>1,'N/A',sum(Units))

jagan
Partner - Champion III
Partner - Champion III

Hi,

Try like this

If(SomeCondition, 'N/A', Sum(MeasureName))

HOpe this helps you.

Regards,

Jagan.

Kushal_Chawda

=if(len(trim(Value))>0, sum(Values),'N/A')

Not applicable
Author

Thanks for all the helpful info.

I already included 'N/A' in my IF statement previously but for some reason the output when the condition is not met shows '-' instead.  I tried changing 'N/A' to other characters but the output still shows '-'. I also tried using the chr() function but it didn't work as well.

Not applicable
Author

I used '*' in the IF statement and it worked...output showed the asterisk when the condition is not met...

jagan
Partner - Champion III
Partner - Champion III

Hi,

Ff you got the answer close this thread by giving Correct and Helpful Answers

Regards,

jagan.