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

Announcements
Save $650 on Qlik Connect, Dec 1 - 7, our lowest price of the year. Register with code CYBERWEEK: Register
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Qlikview Expression problem...help needed

Hello All,

I am using an expression as below

This expression is working fine. However, with this expression, All those meterial codes are being ignored which have False item responses.

I want the count to be shown as above, but for those meterial codes, which have item response=False, I want to show 0 so that the rest of the meterial codes are also shown.

currently only those meterial codes are being shown which have Item response=True. The rest are not being shown because of the above expression. I want the rest of them to be shown with 0

br

Arif

count(if([Item Response]='True',[Material Code])) /count([Material Code])

13 Replies
Not applicable
Author

Hi,

Please, take a look into attached example.

Kind regards,

Janusz

christian77
Partner - Specialist
Partner - Specialist

Well, I didn't mean to solve your problem completely. It was just a substitution of ‘ifs’ by sets.

count({$<[Item Response]={'True'}>} distinct [Material Code])

Counts once every Material Code whose response is True. It does not count absolutely anything else. It does not count items whose response differs from True.

count({$<[Item Response]={'True',’False’}>} distinct [Material Code])

Counts once every Material Code whose response is True or False. If the world is dichotomized in True and False (only these two values exist and there are no null values), then is the same as count(distinct [Material Code])

This one counts every Material Code except those whose response is False.

count({$<[Item Response]={‘*’}-{’False’}>} distinct [Material Code])

same as

count(distinct [Material Code]) - count({$<[Item Response]={'False'}>} distinct [Material Code])

Ok.

kaushiknsolanki
Partner Ambassador/MVP
Partner Ambassador/MVP

Hi,

   Also make one more change.

   Go to properties ->  Presentation -> Uncheck Suppress Zero-Values.

Regards,

Kaushik Solanki

Please remember to hit the 'Like' button and for helpful answers and resolutions, click on the 'Accept As Solution' button. Cheers!
Not applicable
Author

Thank you all,

You have been Awsome. It worked. Thanks Janusz for the correct answer and Thanks Kaushik and Christian for helpful answers. Without your hints, it was not working

Br

Arif