WMA Hub

Tools / DAX library

Fiscal year-to-date total

Accumulate sales from the start of the fiscal year, for fiscal years that do not begin in January.

Fiscal calendars · Advanced · Not yet reviewed

Fiscal YTD Sales =
VAR CurrentFY = MAX('Date'[FiscalYear])
VAR LastDate = MAX('Date'[Date])
RETURN
    CALCULATE(
        [Total Sales],
        FILTER(
            ALL('Date'),
            'Date'[FiscalYear] = CurrentFY
                && 'Date'[Date] <= LastDate
        )
    )

How it works

The measure finds the fiscal year and the last date in the current context, then sums sales for every date in that fiscal year up to the last date. It relies on a FiscalYear column in the date table, so it works for any fiscal start month.

The date table generator on this site can create the FiscalYear column for you.

What your model needs

- A date table named 'Date' with one row per day and no gaps, marked as the date table in Power BI (Table tools > Mark as date table). - A one-to-many relationship from 'Date'[Date] to the date column of the Sales table (for example Sales[OrderDate]). - Total Sales = SUM(Sales[Amount]) (called [Total Sales]). - A numeric FiscalYear column in 'Date' (see the date table generator).

Small example

Input data

Fiscal year starts in July; FY2025 runs Jul 2024 - Jun 2025.
Month | Total Sales
Jul 2024 | 100
Aug 2024 | 120
Sep 2024 | 90

Expected result

Month | Fiscal YTD Sales
Jul 2024 | 100
Aug 2024 | 220
Sep 2024 | 310

Common mistakes and limitations

- If the visual spans two fiscal years, MAX picks the later one. Put fiscal year on the axis or in a slicer. - Check how your company names the fiscal year (by the year it ends or starts) before comparing figures.

Tags: fiscal year, YTD, fiscal calendar