Skip to main content
Announcements
Join us at Qlik Connect for 3 magical days of learning, networking,and inspiration! REGISTER TODAY and save!
cancel
Showing results for 
Search instead for 
Did you mean: 
p_noindl
Partner - Contributor III
Partner - Contributor III

Count excluded values

Hi,

I have to show the number of customer visits by month and number of not visited customers. Because I have several facts (sales by customer and date,..) to show,  it is necessary to make selections by year and month, but have to show the total number of not visited customers within a certain period (total 5 customers, 2 visited, 3 not visited).

Anyone has an idea?

Best regards

1 Solution

Accepted Solutions
bgerchikov
Partner - Creator III
Partner - Creator III

Try expression below for not visited:

count({<Year=,Month=,CustNo=E({$<CustNo={"=count(DateVisit)>0"}>}CustNo)>} DISTINCT CustNo)

or

count({<Year=,Month=,CustNo=E(CustNo)>} DISTINCT CustNo)

View solution in original post

3 Replies
maxgro
MVP
MVP

visited + not visited is always 5?

not visited is all - visited

count({1-$} DateVisit)

bgerchikov
Partner - Creator III
Partner - Creator III

Try expression below for not visited:

count({<Year=,Month=,CustNo=E({$<CustNo={"=count(DateVisit)>0"}>}CustNo)>} DISTINCT CustNo)

or

count({<Year=,Month=,CustNo=E(CustNo)>} DISTINCT CustNo)

p_noindl
Partner - Contributor III
Partner - Contributor III
Author

It worked, many thanks!