March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount! Early bird discount ends December 31.
Register NowBe one of the first to start using Fabric Databases. View on-demand sessions with database experts and the Microsoft product team to learn just how easy it is to get started. Watch now
Customer | Start Date | End Date | |
1 | 2020-01 | 2020-04 | |
2 | 2020-01 | 2020-03 | |
3 | 2020-02 |
Hi, I have a table like the above. I would like to calculate the number of "Active Customers" for each month. Sometimes we have an "End Date" and sometimes we don't (then they are still active).
So for the Example above, I would like an output like this:
2020-01: 2 Active (Customer 1 + 2)
2020-02: 3 Active (Customer 1 + 2 + 3)
2020-03: 3 Active (Customer 1 + 2 + 3)
2020-04: 2 Active (Customer 1 + 3)
2020-05: 1 Active (Customer 3)
2020-06: 1 Active (Customer 3)
Thanks!
Solved! Go to Solution.
I am afriad that will be more complicated. The current data model does not support that visual. please see the attachment below.
Proud to be a Super User!
Hi, @PeterStuhr
Has ryan_mayu’s solution helped you to achieve your requirement? Because his pbix file has perfectly met your needs according to my test.
If so, would you like to mark his as a solution so that others can learn from it too?
Thanks in advance!
How to Get Your Question Answered Quickly
Best Regards,
Community Support Team _Robert Qin
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
you need a datetime table. please see the attachment below
Proud to be a Super User!
Hi @ryan_mayu
Thanks! What if I already have a relation with my calendar date?
I currently have relation Start Date --> Calendar date.
Do I need to ignore that somehow?
If you need the relationship, you can try this
Proud to be a Super User!
Hi @ryan_mayu
Super cool, that works!
However, it doesnt seem to be possible for me to put "legend" like Customer on it. So I can see which customer counts in which months:
Is that possible?
I am afriad that will be more complicated. The current data model does not support that visual. please see the attachment below.
Proud to be a Super User!
Hi, thanks!
your data model does not support you to show that visual and that is also not a good choice. What if you have 100 customers in a month? one chart will be separated to 100 parts.
I suggest you only show numbers and do not put customer ID to legend.
Proud to be a Super User!
March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!
Your insights matter. That’s why we created a quick survey to learn about your experience finding answers to technical questions.
Arun Ulag shares exciting details about the Microsoft Fabric Conference 2025, which will be held in Las Vegas, NV.
User | Count |
---|---|
129 | |
90 | |
75 | |
58 | |
53 |
User | Count |
---|---|
200 | |
104 | |
101 | |
67 | |
55 |