Forum Discussion

ThisIsHalloween's avatar
2 years ago
Solved

Subtracting Two Measures Not Working

I have created two measures that calculate the YTD. Here is what the matrix looks like:   The data comes from two calculated tables that has the current fiscal year data in one table and last...
  • ThisIsHalloween's avatar
    2 years ago

    I got it to work! Here is what I used for future reference:

     

    Difference YTD = 
    VAR PYY =
    TOTALYTD(SUM(PY[Net Amount]), SAMEPERIODLASTYEAR('Date'[Date]), "6-30")
    
    VAR CYY = 
    TOTALYTD(SUM(CY[Net Amount]),
        'Date'[Date],"6-30")
    
    
    RETURN
    CYY-PYY