Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi
I have this datset
ID DATE
3603 01/01/2021
3603 01/02/2021
4076 01/01/2021
4076 01/03/2021
4076 01/02/2021
4101 01/02/2021
I would create a bar chart with
So in my case Bar Chart will be:
01/2021 2 (3603 and 4076)
02/2021 3 (3603 + 4076 of 01/2021 and 4101)
03/2021 3 (3603 + 4076 of 01/2021 + 4101 of 02/2021)
04/2021 3 (3603 + 4076 of 01/2021 + 4101 of 02/2021)
05/2021 3 (3603 + 4076 of 01/2021 + 4101 of 02/2021)
...always the same to 12/2021
I've tried this count(distinct {<DATE={"=aggr(Min(DATE),ID)"},>}ID) but doesn't work
Thank you in advanced
I always recommend Henric's As-Of-Table for any cumulative totals.
Using the following data:
Data:
Load * Inline [
ID,DATE
3603,01/01/2021
3603,01/02/2021
4076,01/01/2021
4076,01/03/2021
4076,01/02/2021
4101,01/02/2021
];
tmpAsOfDate:
Load Distinct [DATE]
Resident Data;
join (tmpAsOfDate)
Load [DATE] as AsOfDate
Resident tmpAsOfDate;
AsOfDate:
Load [DATE],
AsOfDate,
AsOfDate - [DATE] as DayDiff,
Num(Month([AsOfDate]),'00')&'/'&Year([AsOfDate]) as AsOfMonthYear;
Load [DATE],
AsOfDate
Resident tmpAsOfDate
where AsOfDate >= [DATE];
Drop Table tmpAsOfDate;
the Bar Chart dimension is the AsOfMonthYear
The measure is just Count(Distinct ID)