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

Calling all Data Engineers! Fabric Data Engineer (Exam DP-700) live sessions are back! Starting October 16th. Sign up.

Reply
mahenkj2
Solution Sage
Solution Sage

Need help on DAX measure - fetching not related data

Hi,

 

I need help on creating 3 measures, namely TotaQty, TotalAmount, Amount/Qty.

There are 4 tables, all are connected with one to many in one by one cascade. I attach a sample .pbix file, it is a sample version:


https://drive.google.com/file/d/1LKp2GURuu3KDaPvfCc9Cuxo4n8iPY5ct/view?usp=sharing


in my original data, the measure TotalAmount never loads. I think its becuase it fetches all the rows from Table-3 which are not related to filtered FreightID.

 

As I add the TotalAmount measure to the visual, it fetches rows showing InvoiceID which are not related with original FreightID or LNo. I think I need to adjust these measure to work well.

 

My intended output is as below:

FreightIDLNoInvoiceIDQtyTotalQtyTotalAmountAmount/Qty
111200220090004.091
111400220090004.091
112200220090004.091
112600220090004.091
123300220090004.091
124500220090004.091

 

Basically measures should ignore LNo and InvoiceID fields and fetch totals only based on FreightID.

Hope I provided adequate information to resolve it.

2 REPLIES 2
Anonymous
Not applicable

Hi @mahenkj2 ,

 

I've been researching this for a long time and couldn't come up with your expected results, but close. Your initial problem was that the relationship was not set up both ways. The problem now is that once you traverse the table, you get all the row data.

vtianyichmsft_0-1719381672305.png

vtianyichmsft_1-1719381695555.png

An attachment for your reference. Hope it helps!

 

Best regards,
Community Support Team_ Scott Chang

 

If this post helps then please consider Accept it as the solution to help the other members find it more quickly.

 

 

Hi @Anonymous ,

 

Thank you for your time.

 

I saw the attachement but result is not what I am looking for, I see below result:

mahenkj2_0-1719386381341.png

whereas in TotalAmount I wanted to see 9000 and in TotalQty =2200, I believe basically except FreightID, all columns in conext to go off.

Can I achieve that?
P.S. I depend on DAX very little, because just by optimum model design and Power Query, basic DAX is fine, but this time it looks like I need to dig into it or may be I am overcomplicating it.

Helpful resources

Announcements
FabCon Global Hackathon Carousel

FabCon Global Hackathon

Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes!

September Power BI Update Carousel

Power BI Monthly Update - September 2025

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

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.