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

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
Powermac
Frequent Visitor

Different totals: Two separate measures VS One combined measure

Hello:)

 

Could anybody assist me with explaining why I get differerent totals if I

- write two seperate meassures with the second measure using the first or

- write only one measure that contains the whoe but else same code?

 

I have a FxOrder calculation that calculates/looks up the effective exchangerate valid for specific order in an Orders table.  Then I want to multiply each order price with its FxOrder value and sum it up.

 

Option A: A measure for FxOrder and a second, separate measure for Converted Amount that uses FxOrder:

TwoMeasures.JPG

 

Option B: No FxOrder measure but instead, the (same) code for FxOrder written directly in the measure Converted Amount3/2.

Without variables:

OneMeasures1.JPG

With variables:

OneMeasures2.JPG

 

If I write the separate measures, results and totals are as expected. If I write it in one measure, the total is being calcualte differently (multiplicaiotn of the argument totals instead of sum over the single results.

OneVsTwoMeasuresResults.jpg

 

How do I have to understand the order of the calculations and why the totals a different?

 

Many thanks!!

1 REPLY 1
Fowmy
Super User
Super User

@Powermac 


when you create a variable fxordervar and use it in another iteration as SUMX ( orders, fxordervar..... it doesn't get evaluated against each order as the variable once defined, it behaves as a constant. You need to write the complete measure. 

 

Did I answer your question? Mark my post as a solution! and hit thumbs up


Subscribe and learn Power BI from these videos

Website LinkedIn PBI User Group

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

November Power BI Update Carousel

Power BI Monthly Update - November 2025

Check out the November 2025 Power BI update to learn about new features.

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.