Year on year has me stumped

Question
Year on year has me stumped

Posted Oct 23, 2025, 12:58 PM UTC

67
hopkinswyn:MVP_Badge: ‪Microsoft MVP ‪•

What’s your measure for the INSTANCES column?

And do you have a 1 to many relationship between your date table and your fact table?

3
Rsl1209•

Can you share your dax for the YoY column?

2
LittleBitOddOP•

I used the Quick Measure function in the data view. Here's the code (I've replaced some names for privacy reasons):

Count of columnname YoY% = VAR __PREV_YEAR = CALCULATE( COUNTA('tablename'[columnname]), DATEADD('Date'[Date], -1 YEAR) ) RETURN DIVIDE( COUNTA('tablename'[columnname]) - __PREV_YEAR, __PREV_YEAR )

3
Rsl1209•

I don't see anything clearly wrong with your DAX. You could try using SAMEPERIODLASTYEAR instead of DATEADD, it may handle it better, depending on how your date table is setup. Measure would be something like:

VAR __PREV_YEAR =
    CALCULATE (
        COUNTA ( 'tablename'[columnname] ),
        SAMEPERIODLASTYEAR ( 'Date'[Date] ) )
RETURN
    DIVIDE ( COUNTA ( 'tablename'[columnname] ) - __PREV_YEAR, __PREV_YEAR )

Otherwise, I'd be looking at your date table and relationships.

If your base measure that calculates the events works as expected, it's related to how it's handling date transition to the year before.

Be sure the date table is complete and continuous (no missing dates from start to end of period), even if there is no data on some dates. Be sure the relationship is one (from 'date') to many (to events), single direction and active.

2
[deleted]•

[removed]

1
BrotherInJah5•

First of all expose values for your previous year to understand what is returned there. You know, before you divide anything with it.

1
DougalR•

Right so the first two calculations work.

I almost think you’ve got a filter on data prior to mid 2023-2024.

1