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

Announcements
Want to see what's currently in public preview? We've pulled it all together in one place. Check it out here
cancel
Showing results for 
Search instead for 
Did you mean: 
claudialet
Contributor III
Contributor III

How to conditionally display a calculated column ?

  Hi here is my data set:

NameRate
A99%
B89%
C34%
D45%
E 40%

 

Here is the expression:

 

round(Avg({1<Category={'Rate'},Dept_ID={'1'},Test_ID=P(Test_ID)>} Actual_Score)/10000,0.001)

 

How do I display  Name with  values less than  50%   ?

2 Replies
NZFei
Partner - Specialist
Partner - Specialist

Solution 1, do it in dimension:

Change your dimension from Name to

=if(aggr(Avg({1<Category={'Rate'},Dept_ID={'1'},Test_ID=P(Test_ID)>} Actual_Score)/10000,Name)<0.5,Name)

Then uncheck "Include null value".

 

 

 

Solution 2, do it in expression:

Change your expression to:

if(Avg({1<Category={'Rate'},Dept_ID={'1'},Test_ID=P(Test_ID)>} Actual_Score)/10000<0.5,Avg({1<Category={'Rate'},Dept_ID={'1'},Test_ID=P(Test_ID)>} Actual_Score)/10000,0)

Then uncheck "Include zero values" under Add-on.

Note: for solution 2, the calculation for the total line may still include the scores for all names!

Channa
Specialist III
Specialist III

=If(Aggr(round(Avg({1<Category={'Rate'},Dept_ID={'1'},Test_ID=P(Test_ID)>} Actual_Score)/10000,0.001),Name)<=0.5,Name)

 

try to use this in dimension

 

Channa