Forum Discussion

sayantan4336's avatar
sayantan4336
New Member
6 years ago

Subtotal in Data table as measure using DAX

Hi

 

I have a data table which contains column headers Fiscal Year, Net revenue. Data is available for July-18 and Jul-19 in the same table,How do I get subtotals for each fiscal year as measure by using DAX.

1 Reply

  • Hi sayantan4336,

     

    I hope this formula will help for you:

    Previous year=CALCULATE(SUM(netrevenue column, PREVIOUSYEAR('DateTime'[DateKey]))

     

    Current year=CALCULATE(SUM(netrevenue column,YEAR('datetime[datekey]=YEAR(TODAY()))

     

    Cheers,

    Pratima