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
mhsk
Helper II
Helper II

Total sum/multiply working incorectly

This is strange but i hope you will help, so my model looks like this:

image.png

 

 

 

 

 

 

 

 

 

I would like to multiply PurNavLoc[QtyOh.] * PurNavCost[CostPrice] on Part[Part] and ActualDate[Date] level.

 

i created some measures but as long they work in table on single items level they do not want to give proper totals, pelase have a look:

image.png

 

 

 

 

 

Im expecting a total value of 22-07-2019 = 10 878 and 29-07-2019 = 8197 so te total value of items per date but i cant get that:

image.png

 

 

 

 

 

 

 

 

 

 

would you help?

1 ACCEPTED SOLUTION
alexvc
Resolver I
Resolver I

The reason you are getting this inconsistency is because the measure is grouping at the total level as sum. There are two approaches you can try, one is to create a calculated columng for ExtCost = PurNavLoc[QtyOh.] * PurNavCost[CostPrice]. This will add up your extended cost at the total level correctly, since it will sum all of the single ext costs per line.

 

The other one can be to create an ExtCost measure, as SUMX(Part[Part],PurNavLoc[QtyOh.],PurNavCost[CostPrice]), it will sum the multiplication of PurNavLoc[QtyOh.] and PurNavCost[CostPrice] 

 

Let me know if it works

 

Alejandro

View solution in original post

2 REPLIES 2
alexvc
Resolver I
Resolver I

The reason you are getting this inconsistency is because the measure is grouping at the total level as sum. There are two approaches you can try, one is to create a calculated columng for ExtCost = PurNavLoc[QtyOh.] * PurNavCost[CostPrice]. This will add up your extended cost at the total level correctly, since it will sum all of the single ext costs per line.

 

The other one can be to create an ExtCost measure, as SUMX(Part[Part],PurNavLoc[QtyOh.],PurNavCost[CostPrice]), it will sum the multiplication of PurNavLoc[QtyOh.] and PurNavCost[CostPrice] 

 

Let me know if it works

 

Alejandro

hi,

 

it was a bit more complex in my casebut in general sumx solved the problem! Thanks

 

sumx ( TABLE ; expression ) 🙂

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.