Forum Discussion
Use weekvalues 2 years ago as target
Hi all,
i'm trying to use the values from 2 years ago as a target line for the current year. When i create a table it looks like everything works, but when i change it to a chart, it places the values on the wrong year. Anyone can help me understand what i'm doing wrong?
The measure i'm using to create the line values
Norm eigenvertraging =
CALCULATE(SUM('Vertraging'[eigenvertraging])
,DATEADD('Vertraging'[oorzaakdatum].[Date], -2, YEAR)
)
The column oorzaakdatum created it own hierarchy, so in the table i'm using year and month and in the graph i'm using the same column, but no hierarchy column. Just the date.
Anonymous , in such case always use date table, marked as date table and in visual use column from date table
Norm eigenvertraging = CALCULATE(SUM('Vertraging'[eigenvertraging]) ,DATEADD('Date'[Date], -2, YEAR) )Why Time Intelligence Fails - Power bi 5 Savior Steps for TI: https://youtu.be/OBf0rjpp5Hw
2 Replies
- amitchandak
Super User
Anonymous , in such case always use date table, marked as date table and in visual use column from date table
Norm eigenvertraging = CALCULATE(SUM('Vertraging'[eigenvertraging]) ,DATEADD('Date'[Date], -2, YEAR) )Why Time Intelligence Fails - Power bi 5 Savior Steps for TI: https://youtu.be/OBf0rjpp5Hw
- AnonymousNot applicable
amitchandak Tnx! I will create a datatable and set the correct relations and get back to you