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

Earn a 50% discount on the DP-600 certification exam by completing the Fabric 30 Days to Learn It challenge.

Reply
09
Helper I
Helper I

Find the date

Hello all,

For this example below, I wante a DAX measure that returns the change over date from defective to repaired for each ID(the part don't have a unique ID). I tried many formulas but they didn't work for me.

Thanks for your help. 

DatePartIDDesignatorchange over date
20-avrA5022120repaired20-avr
19-avrA5022120defective20-avr
18-avrA5022120defective20-avr
17-avrA5022120defective20-avr
20-avrB3288286repaired19-avr
19-avrB3288286repaired19-avr
18-avrB3288286defective19-avr
17-avrB3288286defective19-avr
20-avrD5235789repaired19-avr
19-avrD5235789repaired19-avr
18-avrD5235789defective19-avr

09_0-1650460386136.png

 

1 ACCEPTED SOLUTION
amitchandak
Super User
Super User

@09 , try a new column like

 

minx(filter(Table, [ID] =earlier([ID]) && [Part_number] =earlier([Part_number]) && [Designator] ="repaired"), [Date])

View solution in original post

2 REPLIES 2
09
Helper I
Helper I

Thank you for your help!

It works.

amitchandak
Super User
Super User

@09 , try a new column like

 

minx(filter(Table, [ID] =earlier([ID]) && [Part_number] =earlier([Part_number]) && [Designator] ="repaired"), [Date])

Helpful resources

Announcements
PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

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

Top Solution Authors