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
JeffH
Helper I
Helper I

Help calculating a cost per piece calculation using a Cost per mile rate that changes each quarter

Need to show cost per piece using a Quaterly changing Cost per Mile Table 

(Cost per piece = miles*Cost per Mile/Pieces)

 

I have a total miles measure and a total pieces measure. 

 

Here is my table. I need two additional columns showing my cost per mile and my cost per piece. 

 

JeffH_0-1602538465610.png

My cost per mile table is below: 

 

JeffH_1-1602538642946.png

 

Any help on how to do this would be appreciated. I cannot seem to duplicate what I did in excel. Probably missing something simple. 

 

4 REPLIES 4
v-shex-msft
Community Support
Community Support

HI @JeffHm

Can you please share the dummy data with the expected result to help us clarify your data structure and test to coding formula on it? How to Get Your Question Answered Quickly 

Regards,

Xiaoxin Sheng

Community Support Team _ Xiaoxin
If this post helps, please consider accept as solution to help other members find it more quickly.
JeffH
Helper I
Helper I

Thank you, but I am still unclear on how to achieve my desired result. 

Hi,

If both your datasets have a Date column, then share the link from where i can download your PBI file.


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/
Ashish_Mathur
Super User
Super User

Hi,

To make the solution easy, there must be a Date column in both datasets.


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/

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.