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

Try your skills in the Power BI Dataviz World Championship! Round one ends June 26. Join now

Reply
Anonymous
Not applicable

Conditional replace values

Hi Community,

 

My data set has data quality issues. In the follwoing sample data set, how can I replace end_date 1/01/1900 with end_date from the row where E_key ,Client_key & program are the same but val = 3 & comment is not null:

 

ExcelPBI_0-1634877421850.png

 

Many thanks!

1 ACCEPTED SOLUTION
amitchandak
Super User
Super User

@Anonymous , a new column

New column =

var _1 = maxx(filter(Table, [E_key] = earlier([E_key) && [End_date] >date(1900,01,01) ), [End Date] )

return

if( [End_date] = date(1900,01,01), _1, [End_date])

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

View solution in original post

1 REPLY 1
amitchandak
Super User
Super User

@Anonymous , a new column

New column =

var _1 = maxx(filter(Table, [E_key] = earlier([E_key) && [End_date] >date(1900,01,01) ), [End Date] )

return

if( [End_date] = date(1900,01,01), _1, [End_date])

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

Helpful resources

Announcements
Fabric Data Days is here Carousel

Fabric Data Days 2026

Don't miss out on Data Days, June 15 through August 7. Learn Fabric, Power BI, SQL, AI and more.

Power BI DataViz World Championships carousel

Power BI DataViz World Championships - June 2026

A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.