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
VTHokie
New Member

DAX to always select value from child table.

Hi,

 

I need a little help with some DAX to always select a value from a child table no matter the filter context.  I have simplified the problem to my core issue in excel.  I have two tables.

 

 Orders

OrderId
100
200
300

 

OrderVersions

OrderIdVersionIdStatusValue
1001Inactive5
1002Inactive10
1003Active30
2001Inactive2
2002Inactive6
2003Active15
2004Pending20
3001Inactive5
3002Active8

 

I want a measure that will always return the Active value for the given OrderId.  I have tried =CALCULATE(SUM([Value]), OrderVersions[Status]="Active") but this only provides the value when the filter context is Status=Active.  

 

Capture.PNG

 

Any help would be appreciated.

 

Mike

1 ACCEPTED SOLUTION
v-juanli-msft
Community Support
Community Support

Hi @VTHokie

Create a measure as below

Measure2 = CALCULATE(SUM(Sheet4[Value]),FILTER(ALLEXCEPT(Sheet4,Sheet4[OrderId]),[Status]="Active"))

6.png

 

Best Regards

Maggie

View solution in original post

1 REPLY 1
v-juanli-msft
Community Support
Community Support

Hi @VTHokie

Create a measure as below

Measure2 = CALCULATE(SUM(Sheet4[Value]),FILTER(ALLEXCEPT(Sheet4,Sheet4[OrderId]),[Status]="Active"))

6.png

 

Best Regards

Maggie

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