Advance your Data & AI career with 50 days of live learning, dataviz contests, hands-on challenges, study groups & certifications and more!
Get registeredGet Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now
I'm just getting started with Power BI and DAX and need to figure out how to create a measure that shows the LastRetailPRice (BI_PurchaseOrderItems[UnitPrice]) of each SKU [BI_Products[ManufacturerCode] ] based on the last time an item with that SKU was on a purchase order (BI_PurchaseOders). The BI_Products table is related to the BI_PurchaseOrderItems table by productID and the BI_PurchaseOders table is related to BI_PurchaseOrderItems by PurchaseOrderId
I' ve found plenty of examples doing this using 1 or 2 tables but so far I'm stuck trying to apply DAX functions where there are 3 related table
@UnlimitydAl , You need to do in two steps , two new columns
New column in BI_PurchaseOrder
LAst Price =
Var _max = maxx(Relatedtable(BI_PurchaseOrderItems), BI_PurchaseOrderItems[PurchaseOrderCreated Date])
return
maxx(filter( BI_PurchaseOrderItems, BI_PurchaseOrderItems [productID] = BI_PurchaseOrder [productID] && BI_PurchaseOrderItems[PurchaseOrderCreated Date] =_max)
, BI_PurchaseOrderItems[UnitPrice])
New column in Products =
maxx(Relatedtable(BI_PurchaseOrder), [LAst Price])
Check out the November 2025 Power BI update to learn about new features.
Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!
| User | Count |
|---|---|
| 5 | |
| 5 | |
| 5 | |
| 4 | |
| 4 |
| User | Count |
|---|---|
| 24 | |
| 21 | |
| 15 | |
| 12 | |
| 10 |