Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
4 years ago
Solved

Add a diff column to a matrix

Hi!   I am reporting on the number of devices per tenant over time. I want to add a third column to the matrix below, showing the the difference between the number of devices per tenant between tod...
  • Whitewater100's avatar
    4 years ago

    Hello:

     

    Assuming you have measure to Count the devices like Total Devices = SUM(Table[Devices])

    You can use DATEADD to get the figure from 7 days ago when you are looking at a particular date.

     

    One Week Ago = CALCULATE( [Total Devices], DATEADD( Dates[Date], -7, Day ) )
     
    I hope this helps.
  • Whitewater100's avatar
    Whitewater100
    4 years ago

    Sorry then 

    subtract the two.

    Difference = [Total Devices] - [Devices 1 week ago]  (the DATEADD measure I just mentioned)