Forum Discussion
ringovski
Helper II
4 years agoMost Recent Date & Value
Hi All, I am trying to get the most recent date and its assoicated active cases value for each LGA Name in a single table NSW. I have written the DAX and it gets the most recent date but it just...
- 4 years ago
Hi,
For calculations using most recent date you can use this logic:
var curdate = max('Calendar'[Date])
var lastestdate = CALCULATE(MAX('Table'[Date]),ALL('Calendar'),'Table'[Date]<=curdate) return
CALCULATE([Measure],'Table'[Date]=latestdate)
I hope this post helps to solve your issue and if it does consider accepting it as a solution and giving the post a thumbs up!
ValtteriN
Community Champion
4 years agoHi,
For calculations using most recent date you can use this logic:
var curdate = max('Calendar'[Date])
var lastestdate = CALCULATE(MAX('Table'[Date]),ALL('Calendar'),'Table'[Date]<=curdate) return
CALCULATE([Measure],'Table'[Date]=latestdate)
I hope this post helps to solve your issue and if it does consider accepting it as a solution and giving the post a thumbs up!