Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
hi ,
I have a table with 3 columns:
Date 2. User_id 3. Flag_1 (0/1)
I want to create 2 new columns that will count the users with flag_1.
First one for the past 30 days (Date-30)
Second for the past 1 day (Date-1)
is someone familiar with this kind of calc.?
thank you
Ilan
Would you be able to share a sample?
hi , sorry I cant attach an example. Trying to count users by flag
count unique users based on Events of Interest such as transaction (flag_1) in two ways
1. last day
2. last 30 days
thank you,
ilan
Hi,
try like
count({<Date={">=Date(max(Date)-30)<=Date(max(Date))"}>}Flag_1)
Note : Careful with Date Format. If required convert it into num and then compare.
Regards
thank you max,
i think Max(date)-30 will retrive the last 30 days from max date in the model or current selection.
i want to count for every day the flag count of the previois 30 (the model holds data of two years)
advanced thanks,
ilan
It seems you want to go back 30 days for every date
Maybe here?
Calculating rolling n-period totals, averages o... | Qlik Community
thank you very much Max. is it possible to use it with a distinct count?