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
groffia
Frequent Visitor

Why is my total correct but calculations using the total wrong?

I'm trying to figure out why this calculation gives me an accurate total:

 

Total Defects:=CALCULATE([All Events],Defects[CA ID]<>"0_DEFECTS",Defects[DISPO_CD]<>"2X -Accept As is(Conforming)",Defects[Begins 0]<>"TRUE")

 

but it doesn't give me accurate numbers when I use this total in other calculations.  It always gives the correct overall but not when drilling down.

 

For example... # of defects yesterday was 122.  When I drill down to a specific assembly line station, station 1, there are 5 defects, but the total remains at 122.

 

My relationships are set, I cannot figure out what else to do.  Any help is appreciated.

2 REPLIES 2
v-yuta-msft
Community Support
Community Support

Hi groffia,

 

Have you create any slicer chart? If you have some slicer, the total value in your measure will be changed by your selection. Only do drill down operation in chart like matrix can't change the result of the measure.

 

Regards,

Jimmy Tao

I figured it out... 

 

The calculations I was working with all pulled the data from the same table in Power Pivot.

 

My overall defects per unit was 0.66 (# of defects/# of machines)

I had calculations for the DPU for each specific cause group... and the DPU for all of those cause groups should've totaled 0.66, but they were each there own stand alone value (# of defects for that specific cause group / # of machines), rather that the numbers being automatically filtered down... so instead of all the cause group DPUs adding up to 0.66, they were being added up one on top of the other.....  .32 + 1.08 + 2.34 + .72 + 0.89, etc....  So my overall DPU was showing as something outrageous like 12.34...

 

Measure for Defects

Measure for # of Machines

 

I had pull a completely new table from the oracle database just for machines.  When I calculated the # of machines on a completely different table, the numbers came out correctly.  I was trying to simplify things by having a single data table rather than several (like I have in the past)... these data tables connect to my lookup tables (date, product family, assembly work areas, etc.)

 

I have no idea why this way works and the other does not.  Thanks for your reply

 

Which doesn't seem like an issue.... 

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.