Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.
HI Power BI Expert,
I'm trying to solve a DAX problerm in Power BI with the following Data:
ID | STATUS CODE |
10000220 | 6 |
10000220 | 5 |
10000221 | 2 |
10000221 | 2 |
10001285 | 5 |
I have a table with two field, "ID" and "STATUS", I would like to find a way to create a calculated column that find if an ID change the Status Code (e.g the Status code in red). I don't mind if the status code is the same, I want to highlight just the different code for the same ID.
Any suggestions?
Best
Solved! Go to Solution.
@Anonymous
is this what you want?
Column =
VAR _a=maxx(FILTER('Table','Table'[ID]=EARLIER('Table'[ID])&&'Table'[STATUS CODE]<>EARLIER('Table'[STATUS CODE])),'Table'[ID])
return if(ISBLANK(_a),blank(),"changed")
if the ID column is text, try this
Column =
VAR _a=maxx(FILTER('Table','Table'[ID]=EARLIER('Table'[ID])&&'Table'[STATUS CODE]<>EARLIER('Table'[STATUS CODE])),'Table'[ID])
return if(_a=""),blank(),"changed")
Proud to be a Super User!
Thank you very much, it works!
you are welcome
Proud to be a Super User!
@Anonymous
is this what you want?
Column =
VAR _a=maxx(FILTER('Table','Table'[ID]=EARLIER('Table'[ID])&&'Table'[STATUS CODE]<>EARLIER('Table'[STATUS CODE])),'Table'[ID])
return if(ISBLANK(_a),blank(),"changed")
if the ID column is text, try this
Column =
VAR _a=maxx(FILTER('Table','Table'[ID]=EARLIER('Table'[ID])&&'Table'[STATUS CODE]<>EARLIER('Table'[STATUS CODE])),'Table'[ID])
return if(_a=""),blank(),"changed")
Proud to be a Super User!
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
106 | |
94 | |
76 | |
62 | |
50 |
User | Count |
---|---|
147 | |
106 | |
104 | |
87 | |
61 |