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

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

Tenure count in multiple months

Hi everyone,


I want to show a chart representing Tenure and a count of customers.

The main complexity is that if a customer has a tenure of 3 weeks, then they should be counted in T1, T2 and T3 so I cannot use an if statement as a calculate dimension (in a way I can see).  I have tried a couple of ways with no success.  I have a customer tenure_weeks and I have generated 1/0 flags for the weeks, so if you have a tenure of 3 weeks you get flagged in T1, T2 and T3.  However, translating this into a functioning table or chart has got me stumped.

Does anyone have any ideas?  Or has anyone dealt with a similar multiple count dimension?

Thanks

Gareth

1 Reply
Not applicable
Author

I think I have just solved it, I've used an unlinked dimension that is simply 1 -> 36 and then my expression is:

=count(distinct  if(tenure_weeks >= Tenure, ID))

This is fine for my development but if I had a very large dataset this might be inefficient so I still welcome better ways of doing this.

Thanks

G