Skip to main content
Announcements
Have questions about Qlik Connect? Join us live on April 10th, at 11 AM ET: SIGN UP NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

expression help

Hi,

Can anyone help highlight what the expression needs to be to count 'Information Refused', and 'Prefer not to say'. The below expression works individually (i.e Count (if (([Religion]) = 'Information Refused',[Client No])) ) but not when I try and put them together:

Count (if (([Religion]) = 'Information Refused', 'Prefer not to say',[Client No]))

The data is below so the result of the expression should be 596.

religion 3.PNG

Appreciate any help on the expression.

1 Solution

Accepted Solutions
Gysbert_Wassenaar

Try Count (if ([Religion] = 'Information Refused' OR [Religion] 'Prefer not to say',[Client No]))


Or better yet use this: Count ({<[Religion] = {'Information Refused','Prefer not to say'}>} [Client No])


talk is cheap, supply exceeds demand

View solution in original post

6 Replies
Gysbert_Wassenaar

Try Count (if ([Religion] = 'Information Refused' OR [Religion] 'Prefer not to say',[Client No]))


Or better yet use this: Count ({<[Religion] = {'Information Refused','Prefer not to say'}>} [Client No])


talk is cheap, supply exceeds demand
tamilarasu
Champion
Champion

Try,

Count ({<[Religion] = {'Information Refused', 'Prefer not to say'}>}[Client No])

Chanty4u
MVP
MVP

=Count (if{<([Religion] = {'Information Refused'}, or  '{[Prefer not to say] }'>},[Client No]))

Kushal_Chawda

Count (if (match([Religion], 'Information Refused', 'Prefer not to say'),[Client No]))

Not applicable
Author

We also need to calculate value present, which is all information on religion - 'Information Refused',' Prefer not to say' and 'NULL'. This is the existing expression which works but only currently brings through NULL:

Count (Religion) - Count (if (Religion= 'NULL',[Client No]))

How can expression be amended to bring through all 3 categories?

Gysbert_Wassenaar

Just add it to the list: Count ({<[Religion] = {'Information Refused','Prefer not to say','NULL'}[Client No])


talk is cheap, supply exceeds demand