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

Compete to become Power BI Data Viz World Champion! First round ends August 18th. Get started.

Reply
Anonymous
Not applicable

Create column with actual status

Hi everyone

I have a problem and I can not solve it.
I have a table like this:

Rick_ferreira_0-1623416227949.png

I need to build a column calculated with the actual status, like this:

Rick_ferreira_1-1623416275226.png

I am trying but probably I am doing something wrong.

Does someone help me?

1 ACCEPTED SOLUTION
Vera_33
Resident Rockstar
Resident Rockstar

Hi @Anonymous 

 

You want a Column in DAX or M? It's one in DAX

Vera_33_0-1623418608781.png

Actual = 
VAR CurP = yourTable[Product]
VAR MaxDate = MAXX(FILTER(yourTable,yourTable[Product]=CurP),[Date])
RETURN
MAXX(FILTER(ALLEXCEPT(yourTable,yourTable[Product]),yourTable[Date]=MaxDate),yourTable[Status])

View solution in original post

1 REPLY 1
Vera_33
Resident Rockstar
Resident Rockstar

Hi @Anonymous 

 

You want a Column in DAX or M? It's one in DAX

Vera_33_0-1623418608781.png

Actual = 
VAR CurP = yourTable[Product]
VAR MaxDate = MAXX(FILTER(yourTable,yourTable[Product]=CurP),[Date])
RETURN
MAXX(FILTER(ALLEXCEPT(yourTable,yourTable[Product]),yourTable[Date]=MaxDate),yourTable[Status])

Helpful resources

Announcements
August Power BI Update Carousel

Power BI Monthly Update - August 2025

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

August 2025 community update carousel

Fabric Community Update - August 2025

Find out what's new and trending in the Fabric community.

Top Solution Authors