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

Earn a 50% discount on the DP-600 certification exam by completing the Fabric 30 Days to Learn It challenge.

Reply
Bone1897
New Member

Pro rating a cost based on start and end date using DAX

Hi all,

 

I have four columns, Circuit, Start Date, End Date and Cost. The period covered might be spanning over few months, for an instance Start Date might be 03/01/2023 and End Date 25/04/2023. I would like to pro rate the cost and to distribute it proportionally accross the whole period as per circuit and month.

 

I would like to limit the number of calculated columns and use measures mostly.

The part highlighted in yellow down on the photo is very important, because the charge is spread over 9 months, and the pro-ration is done based on the number of chargeable days for each month.

 

Thank you very much.Sample.png

1 REPLY 1
lbendlin
Super User
Super User

If you are prorating then you should prorate fairly, by number of days per month.

 

lbendlin_0-1680049438418.png

 

Helpful resources

Announcements
LearnSurvey

Fabric certifications survey

Certification feedback opportunity for the community.

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