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: 
neerajthakur
Creator III
Creator III

Comparing dates in Set Analysis

How can I get count of IDs where Date is more than Today.

 

count({<num(trainingdate)>Today()>} distinct id)

Thanks & Regards,
Please Accepts as Solution if it solves your query.
Labels (4)
1 Solution

Accepted Solutions
Iswarya_
Creator
Creator

Count({$<expirydate={">$(=date(Today(),'YYYY-MM-DD'))"},Flag={1}>} distinct [Ref ID])

 

View solution in original post

8 Replies
Iswarya_
Creator
Creator

Hi @neerajthakur 

Count({$<trainingdate={">$(=date(Today(),'YYYY-MM-DD'))"} >} distinct id)

and make sure that the trainingdate field format matches the format of your formatted today's date

neerajthakur
Creator III
Creator III
Author

I tried but I am getting this error.

xlitzdrama_0-1646125724896.png

 

Thanks & Regards,
Please Accepts as Solution if it solves your query.
Iswarya_
Creator
Creator

Can you try by adding one more bracket ')'

Count({$<trainingdate={">$(=date(Today(),'YYYY-MM-DD'))"} >} distinct id)

Iswarya_
Creator
Creator

If the issue is solved please mark the answer with Accept as Solution

neerajthakur
Creator III
Creator III
Author

Count({<$<expirydate={">$(=date(Today(),'YYYY-MM-DD'))"}>} distinct [Ref ID])

 

It isn't resolved getting set modifier error.

Thanks & Regards,
Please Accepts as Solution if it solves your query.
Iswarya_
Creator
Creator

Please remove one '<' before the expirydate field.

Try like below:

Count({$<expirydate={">$(=date(Today(),'YYYY-MM-DD'))"}>} distinct [Ref ID])

neerajthakur
Creator III
Creator III
Author

How can I include a flag in this statement like Flag={'1'}

Thanks & Regards,
Please Accepts as Solution if it solves your query.
Iswarya_
Creator
Creator

Count({$<expirydate={">$(=date(Today(),'YYYY-MM-DD'))"},Flag={1}>} distinct [Ref ID])