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

Announcements
Join us in Bucharest on Sept 18th for Qlik's AI Reality Tour! Register Now
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

Need Help

Hi all,

I have a data like this...

Customer  Mointh   Contact Name

A              Feb        Rajini

A              Feb        Vijay

A              March     Ajith

A              April       Surya

B              Feb        Shasha

B              March     Divya

C              March     Diya

C              April        Diya

Now I want to show the running total based on customer.

Output should be : "Total Customer for all the three months" - 7 (I.e Feb - 2 distinct customers(A,B), March - 3 distinct customers (A, B, C) April - 2 distinct customers (A,C)..

If I select the Feb Month, Total no of customers should be 2 (A and B).

If I use count(Distinct Customer), 3 is showing for all the three months. But it should show 7.. If I remove distinct , it is counting the duplicate values. For ex in Feb month A customer data is there in two rows. SO it  is showing the total for all the three months 8, If I select Feb Month it is showing 3 but it should show 2..

Can anyone please help me how to achieve this?

1 Solution

Accepted Solutions
sunny_talwar

Try this:

=Sum(Aggr(Count(DISTINCT Customer), Month))

View solution in original post

2 Replies
sunny_talwar

Try this:

=Sum(Aggr(Count(DISTINCT Customer), Month))

Anonymous
Not applicable
Author

Thanks a lot....