Power BI DAX NEXTYEAR function

The Power BI NEXTYEAR function is one of the DAX Date and Time functions useful for returning a table that contains all dates from the next year based on the first date of a given date. This article explains the POWER BI DAX NEXTYEAR function, which accepts the date value and uses the current context to return a column of all dates from the next year. The syntax is shown below.

NEXTYEAR(<dates>)

Power BI DAX NEXTYEAR function Example

To demonstrate the DAX NEXTYEAR() function, click the New Table button on the Modeling Tab and rename it as NextYearSales. The expression calculates and shows the sum of the sales amount for the next OrderDate year in the FactInternetSales table. Please check the sales of the 31-12-2010 and 01-01-2011 dates. Here, 70,75,525.9291 is the sum of the sales of 2010, and 58,42,485.1952 is the 2011 sales.

NextYearSales = CALCULATE(SUM(FactInternetSales[SalesAmount]), NEXTYEAR(FactInternetSales[OrderDate]))
POWER BI DAX NEXTYEAR Function 1

The expression below creates a simple measure to calculate and show the sum of next year’s sales amount. It is based on CalendarTable generated by the CALENDAR function.

To compare present-year sales against next-year sales, we have added the Year of OrderDate, Sales Amount, and the sum of the next-year sales to the table report. Please refer to the DateTime and function article for the remaining Power BI methods. For more Charts >> Click Here.

NextYearCalSale = CALCULATE(SUM(FactInternetSales[SalesAmount]), NEXTYEAR(CalendarTable[Date]))
POWER BI DAX NEXTYEAR Function 2