1
votes

What is the difference between using LASTDATE and MAX to get the last date value.

For example:

LASTDATE ( DateTable[Date]) )

vs

MAX ( DateTable[Date]) )

1
here is a detailed article about it sqlbi.com/articles/…sergiom

1 Answers

2
votes

Type of the return value. LASTDATE returns a table with one row and one column.

Therefore, use cases are different. You use max if you want to display max date or use it as a comparison criterion, whereas lastdate can be used in filter part of CALCULATE, as you pointed out in the comment.