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

Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now

Reply
gmasta1129
Resolver I
Resolver I

Measure total incorrect in Table

Hello,

 

I have a pretty simple formula in my measure.  

 

FundStrat% = [% of Eligible Assets] * CALCULATE(SUM(enav_raw_input[Invest. Strat - Risk Parameter Score]))
 
When I add this measure into my table and turn on the "Totals", I do not get the correct value.  Is it not possible to get the correct total for measures? 
 
Please note, I have two filters (dropdown filters) on my table (see below). Not sure if the filters are the issue? 
1. Run Date
2. Facility Code
 
 
1 ACCEPTED SOLUTION
Poojara_D12
Super User
Super User

Hi @gmasta1129 

In Power BI, it’s common to encounter issues where the total row of a measure does not reflect the expected sum of individual rows, and this is due to how DAX measures are evaluated in the context of totals. Your measure, FundStrat% = [% of Eligible Assets] * CALCULATE(SUM(enav_raw_input[Invest. Strat - Risk Parameter Score])), works correctly on a row-by-row basis because the row context allows DAX to evaluate the values of each row individually. However, when the "Total" is calculated, DAX evaluates the measure in the context of the total group, meaning it no longer computes each row individually and sums them, but rather evaluates the expression once over the entire filtered dataset. This can lead to unexpected results—especially when your measure involves row-level multiplication, like multiplying one measure by a row-dependent sum.

 

Additionally, the presence of filters like "Run Date" and "Facility Code" affects the context in which both the rows and the total are calculated. These filters may restrict the dataset correctly, but they don’t change the fact that totals are computed in a different evaluation context.

 

To get an accurate total, you may need to rewrite the measure to explicitly aggregate the row-level results. For example, using SUMX, which iterates over each row in a table and performs the calculation per row before summing, can fix this:

FundStrat% = SUMX(
    VALUES(enav_raw_input[SomeGroupingColumn]),
    [% of Eligible Assets] * CALCULATE(SUM(enav_raw_input[Invest. Strat - Risk Parameter Score]))
)

Replace SomeGroupingColumn with the column that defines the row-level granularity of your table. This approach forces DAX to mimic row-by-row evaluation even at the total level, providing the accurate sum you expect.

 

Did I answer your question? Mark my post as a solution, this will help others!
If my response(s) assisted you in any way, don't forget to drop me a "Kudos"

Kind Regards,
Poojara - Proud to be a Super User
Data Analyst | MSBI Developer | Power BI Consultant
Consider Subscribing my YouTube for Beginners/Advance Concepts: https://youtube.com/@biconcepts?si=04iw9SYI2HN80HKS

View solution in original post

6 REPLIES 6
Poojara_D12
Super User
Super User

Hi @gmasta1129 

In Power BI, it’s common to encounter issues where the total row of a measure does not reflect the expected sum of individual rows, and this is due to how DAX measures are evaluated in the context of totals. Your measure, FundStrat% = [% of Eligible Assets] * CALCULATE(SUM(enav_raw_input[Invest. Strat - Risk Parameter Score])), works correctly on a row-by-row basis because the row context allows DAX to evaluate the values of each row individually. However, when the "Total" is calculated, DAX evaluates the measure in the context of the total group, meaning it no longer computes each row individually and sums them, but rather evaluates the expression once over the entire filtered dataset. This can lead to unexpected results—especially when your measure involves row-level multiplication, like multiplying one measure by a row-dependent sum.

 

Additionally, the presence of filters like "Run Date" and "Facility Code" affects the context in which both the rows and the total are calculated. These filters may restrict the dataset correctly, but they don’t change the fact that totals are computed in a different evaluation context.

 

To get an accurate total, you may need to rewrite the measure to explicitly aggregate the row-level results. For example, using SUMX, which iterates over each row in a table and performs the calculation per row before summing, can fix this:

FundStrat% = SUMX(
    VALUES(enav_raw_input[SomeGroupingColumn]),
    [% of Eligible Assets] * CALCULATE(SUM(enav_raw_input[Invest. Strat - Risk Parameter Score]))
)

Replace SomeGroupingColumn with the column that defines the row-level granularity of your table. This approach forces DAX to mimic row-by-row evaluation even at the total level, providing the accurate sum you expect.

 

Did I answer your question? Mark my post as a solution, this will help others!
If my response(s) assisted you in any way, don't forget to drop me a "Kudos"

Kind Regards,
Poojara - Proud to be a Super User
Data Analyst | MSBI Developer | Power BI Consultant
Consider Subscribing my YouTube for Beginners/Advance Concepts: https://youtube.com/@biconcepts?si=04iw9SYI2HN80HKS
Anonymous
Not applicable

Hi @gmasta1129 
I wanted to check if you had the opportunity to review the information provided by @Deku . Please feel free to contact us if you have any further questions. If his response has addressed your query, please accept it as a solution and give a 'Kudos' so other members can easily find it.
Thank you.

Anonymous
Not applicable

Hi @gmasta1129 
Thank you for reaching out microsoft fabric community forum.

May I ask if you have resolved this issue? If so, please mark the helpful reply and accept it as the solution. This will be helpful for other community members who have similar problems to solve it faster.

Thank you.

gmasta1129
Resolver I
Resolver I

The value (output) in the measure I provided above is calculated correctly. Its when I click on "Totals" in the visualizations section of Power BI. This column does not show the correct total at the bottom of the table I created.

 

Ex: 

Fundstrat%

5

4

8

9

Total on the Table currently shows= 20,000

I should see 26 (5+4+8+9)

 

I would suggest showing [% of Eligible Assets] and CALCULATE(SUM(enav_raw_input[Invest. Strat - Risk Parameter Score])) as separate columns in the table to debug.

 

There is not enough information to understand where your issue is.


Did I answer your question?
Please help by clicking the thumbs up button and mark my post as a solution!
Deku
Super User
Super User

What do you mean by wrong? What do you expect?

 

Can you share the definition of the other measure, what you are seeing now and the expected output.


Did I answer your question?
Please help by clicking the thumbs up button and mark my post as a solution!

Helpful resources

Announcements
November Power BI Update Carousel

Power BI Monthly Update - November 2025

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

Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

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.