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

Aggregating values by one column, then attaching this value to a more detailed level

I have the following data structure:

 

- Table "Plan" which joins to table "Planning" on PlanKey 1 to many relationship single direction

- Table "PlanningClass" which joins to "Planning" On PlanClassKey, 1 to many single direction

- Table "PlanningClass" also joins to table "Amounts" on PlanClassKey, 1 to many, single direction

- Table "Amounts" joins to table "Risk" on RiskID on a many to 1 relationship, both direction

- Table "Risk" joins also to "Planning" on RiskID as a 1 to many relationshiop, single direction.

 

I want to create a measure which sums another measure location on the "Planning" table grouped up by PlanningClassName (a column in the Planning Class Table. This measure should then show the aggregated value for each plan class name to a table which has multiple columns in the Risk table (whose unique ID is riskID for each row).

 

Here's what I have:

 

PlanAmountAggregated =
CALCULATE(
    [Sum of Plan Amount],
    'Plan'[Plan Basis] = "abc",
    'Plan'[Default Plan] = TRUE,
    ALLEXCEPT('Planning Class', 'Planning Class'[Planning Class Name]))
 
this shows the correct amount in a simple table of planning class name & amount; however if I then add in RiskID it doesn't show the correct amount for each risk id; despite there being a Planning Class Name for each risk ID which comes from the link to the Amounts table and then back to the Risk table.
 
I have tried many things but nothing seems to work. How do I do this?
1 REPLY 1
lbendlin
Super User
Super User

Please provide sample data that covers your issue or question completely, in a usable format (not as a screenshot).

Do not include sensitive information or anything not related to the issue or question.

If you are unsure how to upload data please refer to https://community.fabric.microsoft.com/t5/Community-Blog/How-to-provide-sample-data-in-the-Power-BI-...

Please show the expected outcome based on the sample data you provided.

Want faster answers? https://community.fabric.microsoft.com/t5/Desktop/How-to-Get-Your-Question-Answered-Quickly/m-p/1447...

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.

Top Solution Authors