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: 
Anonymous
Not applicable

if statement to reduce dimensions

I have an expression which calculates a % of coverage. I would like to limit the dimensions to where the coverage is 10% or more. The dimension is 'Insight' and the following is the expression for coverage (which i know works)

=count(if(isnull(Category) and ExcludeWord<>'Yes' and not(isnull(Topic)),Topic))/(sum(if(not(isnull(Category)),TopicFlag))+count(if(isnull(Category) and ExcludeWord<>'Yes' and not(isnull(Topic)),Topic)))

adding the expression into the if statement doesnt seem to be working

if(count(if(isnull(Category) and ExcludeWord<>'Yes' and not(isnull(Topic)),Topic))/(sum(if(not(isnull(Category)),TopicFlag))+count(if(isnull(Category) and ExcludeWord<>'Yes' and not(isnull(Topic)),Topic)))>0.1, Insight)

1 Solution

Accepted Solutions
sunny_talwar

May be try this

Aggr(if(count(if(isnull(Category) and ExcludeWord<>'Yes' and not(isnull(Topic)),Topic))/(sum(if(not(isnull(Category)),TopicFlag))+count(if(isnull(Category) and ExcludeWord<>'Yes' and not(isnull(Topic)),Topic)))>0.1, Insight), Insight)

View solution in original post

4 Replies
YoussefBelloum
Champion
Champion

Hi,

what type of objects are you using to dispay the reduced dimensions?

Anonymous
Not applicable
Author

Just a bar chart

YoussefBelloum
Champion
Champion

you can simply add the condition on the expression. did you try it ?

sunny_talwar

May be try this

Aggr(if(count(if(isnull(Category) and ExcludeWord<>'Yes' and not(isnull(Topic)),Topic))/(sum(if(not(isnull(Category)),TopicFlag))+count(if(isnull(Category) and ExcludeWord<>'Yes' and not(isnull(Topic)),Topic)))>0.1, Insight), Insight)