Forum Discussion
IF on date - Expressions that yield variant data-type...
- 8 years ago
Ha! I've found the solution! :)
Status date = If('Status date'[Status date_date]=maX('Status date'[Status date_date]);"Last status";format('Status date'[Status date_date];"YYYY-MM-DD"))
You can't have the dates and the 'Last Date' together in one column/slicer, (for as far as i know)
So what should I do?
I would like to set the slicer on "Last status" so when the data is refreshed and there are new statuses, the report always shows the newest status.
- BeemsC8 years agoResolver III
Yea, like i said. You were good on your way with the formula. But its not possible for both the dates and "Last date".
If you use something like :
Column2 = IF('Status date'[Status date]=MAX('Status date'[Status date]);"Last status";"Not last status")
Or alternatively, if you only want "Last status"
Column2 = IF('Status date'[Status date]=MAX('Status date'[Status date]);"Last status";"")
Then you just add column 2 to a slicer. And if your relationships are correct, it should work- AnetaK8 years agoHelper V
Ha! I've found the solution! :)
Status date = If('Status date'[Status date_date]=maX('Status date'[Status date_date]);"Last status";format('Status date'[Status date_date];"YYYY-MM-DD"))