Join us for an expert-led overview of the tools and concepts you'll need to pass exam PL-300. The first session starts on June 11th. See you there!
Get registeredPower BI is turning 10! Let’s celebrate together with dataviz contests, interactive sessions, and giveaways. Register now.
Hi, I have a customer dimension structured like the below
I have a FACT table like the below (joined using CustomerKey)
I want to add a column to my customer dimension table which gets me the latest Product Name, and Order Date from the FACT table where OrderComplete = 0. It should get me the one that has the latest Order date...So this would give me an output of the below
How could I build this calculated column using DAX?
Thanks
Solved! Go to Solution.
LatestProductName =
MAXX(
TOPN(
1,
FILTER( RELATEDTABLE( 'FACT' ), 'FACT'[OrderComplete] = 0 ),
'FACT'[OrderDate]
),
'FACT'[ProductName]
)
LatestProductDate =
CALCULATE( LASTDATE( 'FACT'[OrderDate] ), 'FACT'[OrderComplete] = 0 )
Expertise = List.Accumulate( {Days as from Today}, {Skills and Knowledge}, (Current, Everyday) => Current & Day.LearnAndPractise(Everyday) ) |
LatestProductName =
MAXX(
TOPN(
1,
FILTER( RELATEDTABLE( 'FACT' ), 'FACT'[OrderComplete] = 0 ),
'FACT'[OrderDate]
),
'FACT'[ProductName]
)
LatestProductDate =
CALCULATE( LASTDATE( 'FACT'[OrderDate] ), 'FACT'[OrderComplete] = 0 )
Expertise = List.Accumulate( {Days as from Today}, {Skills and Knowledge}, (Current, Everyday) => Current & Day.LearnAndPractise(Everyday) ) |
Hi,
try creating a these measures:
User | Count |
---|---|
85 | |
79 | |
64 | |
52 | |
46 |
User | Count |
---|---|
101 | |
44 | |
41 | |
39 | |
36 |