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
Anonymous
Not applicable

Aggregation issue

I have an issue with the following table I created in Power BI.
Why is the sum of Outer Square only calculated per Variant Code and not among all entries?

 

2018-11-23_15-01-24.jpg

1 ACCEPTED SOLUTION
Anonymous
Not applicable

Ok, this simple measure did work:

 

AQMtotal = 'Production Order'[Quantity]*RELATED('Production BOM Header'[Outer Square])

 

View solution in original post

5 REPLIES 5
v-juanli-msft
Community Support
Community Support

Hi @Anonymous

If only the total sum is incorrect, other values in the [Outer Square] column is right, you could write a measure for a temparay solution.

Measure = IF(HASONEVALUE('value'[entry no]),MAX([outer square]),SUMX(ALL('value'),[outer square]))

6.png

To find why cause this problem, please provide detailed information, so i can reproduce your problem.

which table do the columns [entry no], [variant code], [outer square] from?

which are the key columns(create relationship based on) among three tables?

 

Best Regards

maggie

 

 

Anonymous
Not applicable

I didn't get it with a measure - but I can provide my pbix:

https://1drv.ms/u/s!Ai9Gkt_8r-5VlA4MEhngEGiiacPu

 

The issue is about the table on the bottom right side. 
I added the quantity, so I don't have to many entries per variant code. 

 

Anonymous
Not applicable

Ok, this simple measure did work:

 

AQMtotal = 'Production Order'[Quantity]*RELATED('Production BOM Header'[Outer Square])

 

Greg_Deckler
Community Champion
Community Champion

That depends on whether Outer Square is a column or a measure. If it is a measure, see my post about it here: https://community.powerbi.com/t5/DAX-Commands-and-Tips/Dealing-with-Measure-Totals/td-p/63376

Also, this Quick Measure, Measure Totals, The Final Word should get you what you need:
https://community.powerbi.com/t5/Quick-Measures-Gallery/Measure-Totals-The-Final-Word/m-p/547907



Follow on LinkedIn
@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
DAX For Humans

DAX is easy, CALCULATE makes DAX hard...
Anonymous
Not applicable

I didn't work with measures yet. In this case it's just two tables connected through a third table:

2018-11-26_10-23-43.jpg

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!

December 2025 Power BI Update Carousel

Power BI Monthly Update - December 2025

Check out the December 2025 Power BI Holiday Recap!

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.