From the course: Advanced Power BI: DAX Language, Formulas, and Calculations

Unlock the full course today

Join today to access over 24,400 courses taught by industry experts.

EOMONTH DAX function

EOMONTH DAX function

- Time intelligence and date calculations are one of the big strengths of DAX. One function I find quite useful is the EOM month function, which is shorthand for end of the month. It takes an input date as the first parameter. The second parameter of this function specifies how many months we want to move the date at the end of the month, forward or backwards. One example of why we might want to move our dates in a Power BI model around is to match up the timelines of dates that otherwise don't align. For example, the interest rate we selected based on the user controlled input in the date slicer returns dates on a weekly frequency. The dates we're using to calculate the Model 2 Loan measures though, use the first date of the month. They're not connected to the selected date measure in the user controlled slicer, which references the interest rate table. We want our loan to start on the first day of the next month after…

Contents