Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!To celebrate FabCon Vienna, we are offering 50% off select exams. Ends October 3rd. Request your discount now.
Hi, I have the below table with dates ranging from 2018.04.01 to 2019.04.01 with multiple payments in each month for multiple policies:
I need a measure that returns the latest date in that column, so I used LASTDATE(Payments[PaymentDate].[Date]), but that returns 2019.12.31, not 2019.04.01. Why could this be? Thanks!
Solved! Go to Solution.
Except that 2019.12.31 is not among the existing values in that column, 2019.04.01 is the last. 😉
A friend of mine helped me out and LASTDATE(Payments[PaymentDate]) without .date at the end gave me the expected result, thanks!
I had same issue where the FIRSTDATE formula pulled the very first date of its year, rather than the first date within the record...
I fixed with using MIN/MAX instead + not using the .[date] like Zoltan.
I have no idea why this fixes it but it is fixed...
Read your question once again. 2019.12.31 is definitely > 2019.04.01 so the measure is working fine.
Except that 2019.12.31 is not among the existing values in that column, 2019.04.01 is the last. 😉
A friend of mine helped me out and LASTDATE(Payments[PaymentDate]) without .date at the end gave me the expected result, thanks!