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

Announcements
Qlik GA: Multivariate Time Series in Qlik Predict: Get Details
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

condition

Hello,

I put this expression to count Users who made orders in 2012 and 2013:


count({<Order-Year=2012, Order-Year=2013>}DISTINCT UserPK)

but it doesn't work, the second condition is not considered.

plz help

12 Replies
Not applicable
Author

Try this,

count({<Order-Year={2012,2013}>}DISTINCT UserPK)

Thanks

somenathroy
Creator III
Creator III

count({<Order-Year={'2012','2013'}>}DISTINCT UserPK)


Regards,

som

alexandros17
Partner - Champion III
Partner - Champion III

if Order-Year is a field you have to

count({$ <[Order-Year]={'>=2012<=2013'}>}DISTINCT UserPK)

hope it helps

Not applicable
Author

thank u, but it doesn't work

I have 781 users in 2012

          409 users in 2013

    when I use this expression it gives 906 users!!

it must be less than 409

Gysbert_Wassenaar
Partner - Champion III
Partner - Champion III

Try count({<[Order-Year]={2012}>,UserPK=p({<[Order-Year]={2013}>}UserPK)>} DISTINCT UserPK)


talk is cheap, supply exceeds demand
Not applicable
Author

the same result

Not applicable
Author

if(Order-Year=2012 and Order-Year = 2013, count(distinct UserPK))

Not applicable
Author

try this

count({<UserPK=p({<[Order-Year]={'2012','2013'}>}UserPK)>} DISTINCT UserPK)

Not applicable
Author

@ Mr. Gysbert Wassenaar : there is an error in this expression