Qlik Community

Qlik Sense App Development

Discussion board where members can learn more about Qlik Sense App Development and Usage.

Not applicable

Total shows '0' for Conditional Counting in Qlik Sense Chart

Hello Guys,

I am trying to achieve conditional counting by comparing two measures A and B and count only when A>B. I was able to achieve this by a simple expression in chart measure

if(A>, count(A), 0).

The problem is with the Total in the Chart (Which I cannot remove in Qlik Sense) shows '0' for that measure. Please find the screen cap for the reference. Let me know if I am missing something. Thanks for your help.

Conditional Counting.PNG

1 Solution

Accepted Solutions

Re: Total shows '0' for Conditional Counting in Qlik Sense Chart

Try this:

Sum(Aggr(If(A > B, Count(A), 0), Competition, A, B))

2 Replies

Re: Total shows '0' for Conditional Counting in Qlik Sense Chart

Try this:

Sum(Aggr(If(A > B, Count(A), 0), Competition, A, B))

Not applicable

Re: Total shows '0' for Conditional Counting in Qlik Sense Chart

Wow that was quick. I didn't know how it worked (I am new to Qlik) but will analyze the expression and make sure I remember this. Thanks Sunny.

Community Browser