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

Measure Grand total not matching

Hello team,

 

i have created a measure where the grand total should be £96656.89 but im getting a different grand total.

 

This is my measure :

GBPConverstion =
var convertgbp = CALCULATE(
SUM('FX Rates'[GBP_Avg]) * [Card Spend GBP],
USERELATIONSHIP(Presentment[Settlement Date],FeeDate[Date]),
USERELATIONSHIP(FeeDate[Months],'FX Rates'[Months])
)
var previousmonthfx = CALCULATE(
SUMX('FX Rates','FX Rates'[GBP_Avg]),
PREVIOUSMONTH(FeeDate[Date])
)
var previousmth = CALCULATE(
[Card Spend GBP] * previousmonthfx,
USERELATIONSHIP(Presentment[Settlement Date],FeeDate[Date]),
USERELATIONSHIP(FeeDate[Months],'FX Rates'[Months])
)
return
IF(convertgbp=BLANK(),previousmth,convertgbp)

 

Screenshot 2020-11-30 at 17.19.10.png

 

please could you help

1 ACCEPTED SOLUTION
mahoneypat
Employee
Employee

Please try this to get the correct total.  It references your existing measure.  Use it in place of your current measure in the visual.  

 

New GBPConversion = SUMX(VALUES('Date'[Month]), [GBPConversion])

 

Regards,

Pat 





Did I answer your question? Mark my post as a solution! Kudos are also appreciated!

To learn more about Power BI, follow me on Twitter or subscribe on YouTube.


@mahoneypa HoosierBI on YouTube


View solution in original post

3 REPLIES 3
mahoneypat
Employee
Employee

Please try this to get the correct total.  It references your existing measure.  Use it in place of your current measure in the visual.  

 

New GBPConversion = SUMX(VALUES('Date'[Month]), [GBPConversion])

 

Regards,

Pat 





Did I answer your question? Mark my post as a solution! Kudos are also appreciated!

To learn more about Power BI, follow me on Twitter or subscribe on YouTube.


@mahoneypa HoosierBI on YouTube


Thank you for this. That did work.

However i really didnt want to call it to another measure. Is there a way, where i could have it all in one measure?

Hi @viralpatel21 ,

 

It may need to transform the measure into a table (virtual table) and use the table as a parameter in your measure expression.  Then sumx("the virtual table", [the transformed column]). If you can show me some data and I'll test for you.

 

 

Best regards

Icey

 

If this post helps, then consider Accepting it as the solution to help other members find it faster.

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.

Top Solution Authors
Top Kudoed Authors