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

Find everything you need to get certified on Fabric—skills challenges, live sessions, exam prep, role guidance, and more. Get started

Not applicable

Sum of values based on distinct values in other column

Hello my name is Leonardo , and i have problem with this table. 

It has repetitive values and i want to calculate some measures


The table shows the volume in "M3" for each SKU produced, as well as the Volume of "Lubrication Consumption (M3)" and "Washing Machine Consumption (M3)", which are the same for each "LINE". The general consumption of water on the "Consumption M3" day is also shown. What I want to calculate: "Other Consumption (m3)" = "Consumption M3" - "Consumption Lubrication (m3)" - "Washing Machine Consumption (m3)"; for each day. for example: For 03/01/2018 would have Other consumptions (m3) = 686 - (41 + 21 + 40 + 0) - (135 + 100 + 0 + 154). Likewise I want to calculate the WUR (Water Usage Ratio) = ((Sum of "M3") + (Sum "of Consumption M3")) / (Sum of "M3"), for each day. For example: For 03/01/2018 I would have WUR VDR = ((28 + 107 + 68 + ....) + 686) / (28 + 107 + 68 + ..)


Please help me, I've broken my head trying to calculate it with distinct but it still does not work out. My entire thanks. Leonardo LIMA PERU


Super User
Super User

Helpful resources

July 2024 Power BI Update

Power BI Monthly Update - July 2024

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

July Newsletter

Fabric Community Update - July 2024

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