Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
Anonymous
Not applicable

Cumulative count between 2 dates column.

Hi All, 

 

I have a property data with columns start date and end date. I want to find the cumulative count of the property live based on the start date and end date based on the property status. 

 

Sample data:

 

Property IDProperty namestart dateend datestatus
10001xyz Motor Inn 20/03/2020 Live
10000ABCy Villa 21/03/202020/04/2019Terminated
10003 81 Hotel24/03/2020 Live
10004113 motel inn24/03/2020 Live
100ABC Lodge20/04/2020 Live
10005 The Rope club25/04/2020 Live
10006 Tiny Island 26/04/2020 Live
10007Number41 serviced Apartments27/04/2020 Live
10008402 Morocco inn 28/04/2020 Live

 

 

1. When the end date is empty, the property is still live and can be counted. 

2. If the property is terminated, then the count will be applied only till the end date.

 

Expected output:

 

Property IDProperty namestart dateend datestatusLive_count
10001xyz Motor Inn 20/03/2020 Live1
10000ABCy Villa 21/03/202020/04/2019Terminated2
10003 81 Hotel24/03/2020 Live4
10004113 motel inn24/03/2020 Live4
100ABC Lodge20/04/2020 Live5
10005 The Rope club25/04/2020 Live5
10006 Tiny Island 26/04/2020 Live6
10007Number41 serviced Apartments27/04/2020 Live7
10008402 Morocco inn 28/04/2020 Live8

 

I am not sure how to achieve this in Power BI. 

 

Thanks,

Kanthi.

2 REPLIES 2
Pragati11
Super User
Super User

Hi @Anonymous ,

 

This doesn't help in answering your query. You want to calculate SUM of COUNTS of which column?

Can you please screesnhot some sample data with few rows?

 

Thanks,

Pragati

Best Regards,

Pragati Jain


MVP logo


LinkedIn | Twitter | Blog YouTube 

Did I answer your question? Mark my post as a solution! This will help others on the forum!

Appreciate your Kudos!!

Proud to be a Super User!!

Anonymous
Not applicable

Hi @Pragati11

 

Updated the query with some 10 sample data and expected solution. I hope this gives an idea, please let me know if it needs further more clarity. 

 

Thanks,

Kanthi.

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.

Top Solution Authors