Qlik Community

New to Qlik Sense

If you’re new to Qlik Sense, start with this Discussion Board and get up-to-speed quickly.

Announcements
Qlik Insider: SaaS capabilities for Data Integration and Analytics, May 25th! Register Now
cancel
Showing results for 
Search instead for 
Did you mean: 
lmcsedyz
Contributor II
Contributor II

invalid Dimension? - if count distict is more then 3

Hi, I have datasource with messages from people to clients, people (candidate) belong to client.

Every candidate has date/time of his reply.

I wish to see if client has enough of candidates. I can save this dimension, but it does not work - ERROR message Invalid dimension

IF((Count (distinct EMAIL)) > 3, '4 and more', if((Count (distinct EMAIL)) < 4,'3 and less'))

If I create new datasource with calculated Count (distinct EMAIL) it works


IF(LIFETIME_emails > 3, '4 and more', if(LIFETIME_emails < 4,'3 and less'))


but with this i cannot work with date dimension or atributes of messages...


Please help



1 Solution

Accepted Solutions
sunny_talwar

You need Aggr() function when using Count, Sum type of functions in your dimension.

Try like this:

Aggr(If(Count(DISTINCT EMAIL) > 3, '4 and more', '3 and less'), Client)

View solution in original post

3 Replies
sunny_talwar

You need Aggr() function when using Count, Sum type of functions in your dimension.

Try like this:

Aggr(If(Count(DISTINCT EMAIL) > 3, '4 and more', '3 and less'), Client)

vinay_bangari
Specialist III
Specialist III

i agree with Sunny if that does not solve the problem please share us your sample QVF file.

lmcsedyz
Contributor II
Contributor II
Author

Thank you very much, Sunny T