Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi all,
I need to count a number of customer using services in last 1m/3m or 6m, so that i set an expression like that:
count({<[TransDate]={'>=$(admonths(today(),-1))'}>} distinct [Cus.No]) ==> for 1M
count({<[TransDate]={'>=$(admonths(today(),-3))'}>} distinct [Cus.No]) ==> for 3M
count({<[TransDate]={'>=$(admonths(today(),-6))'}>} distinct [Cus.No]) ==> for 6M
However, all these three expressions show the same result!
Please help me to correct that expression. Thank you!
Regards,
PhucPV
Try with an equal sign within the dollar sign expansion and also switch single quotes to double quotes and see if that works
count({<[TransDate]={">=$(=admonths(today(),-1))"}>} distinct [Cus.No]) ==> for 1M
count({<[TransDate]={">=$(=admonths(today(),-3))"}>} distinct [Cus.No]) ==> for 3M
count({<[TransDate]={">=$(=admonths(today(),-6))"}>} distinct [Cus.No]) ==> for 6M
Try with an equal sign within the dollar sign expansion and also switch single quotes to double quotes and see if that works
count({<[TransDate]={">=$(=admonths(today(),-1))"}>} distinct [Cus.No]) ==> for 1M
count({<[TransDate]={">=$(=admonths(today(),-3))"}>} distinct [Cus.No]) ==> for 3M
count({<[TransDate]={">=$(=admonths(today(),-6))"}>} distinct [Cus.No]) ==> for 6M
When applicable please mark the appropriate replies as CORRECT. This will help community members and Qlik Employees know which discussions have already been addressed and have a possible known solution. Please mark threads as HELPFUL if the provided solution is helpful to the problem, but does not necessarily solve the indicated problem. You can mark multiple threads as HELPFUL if you feel additional info is useful to others.
Yesss, it works great bro! thank you so much for your prompt help!!!