Advance your Data & AI career with 50 days of live learning, dataviz contests, hands-on challenges, study groups & certifications and more!
Get registeredGet Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now
I'm trying to return the last non-blank row of the "Target stage outcome" column based on the "Entity" column. However, using the lastnonblank dax formula is not yielding the correct results.
I have attached the example fact table below.
Here is the results that I'm trying to get are those in the red box:
I've created a summary table to see the results
Despite the "Index" and "Last day" returning the correct results, the "Stage" field is not returning the correct result.
This is the "Target" table that I'm using in my summary table above
I would appreciate if someone could help me here.
Thanks
Solved! Go to Solution.
try LASTNONBLANKVALUE(Target[Reponse Date],MAX(Target[Target Stage Outcome]))
LASTNONBLANK, sorts the column in the first parameter, then get the last value of which the second parameter is non blank
@wdx223_Daniel Would that mean that it would sort the "target stage outcome" first then only determine the lastnonblank for the "Response date"?
try LASTNONBLANKVALUE(Target[Reponse Date],MAX(Target[Target Stage Outcome]))
Thanks @wdx223_Daniel. It worked but should there be the same date, then it doesn't work as intended. How should I deal with it if I dont use the "Response date" field?
how about using the Target[Index] as the first parameter?
Check out the November 2025 Power BI update to learn about new features.
Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!
| User | Count |
|---|---|
| 5 | |
| 5 | |
| 4 | |
| 4 | |
| 3 |
| User | Count |
|---|---|
| 24 | |
| 21 | |
| 12 | |
| 10 | |
| 8 |