Forum Discussion
Forecasting project by day
- Anonymous7 years ago
HI lisampederson,
#1. It seems like I forget to calculate rolling total, I modify my measure to change conditions, now it can be summarized based current year.
Total Attribute = var currDate=MAX('Expand Table'[Detail Date]) return CALCULATE ( SUM ( 'Expand Table'[Daily cost] ), FILTER ( ALLSELECTED ( 'Expand Table' ), [Detail Date] <= MAX ( [Detail Date] ) && YEAR ( [Detail Date] ) = YEAR (currDate ) ), VALUES ( 'Calculator'[Unique Key] ) )#2. Since I used original table to generate expand table, so if you direct create relationship between these table columns, it will return a 'circular dependency' error. In my opinion, you can try to create a bridge table with relationship key to link these tables.
Notice: Unique key is merged with project id and attribute column.
Regards,
Xiaoxin Sheng
Updated document:
https://docs.google.com/spreadsheets/d/1czqbCytHOCI7RmojQL1gjK4KXwNRkviV6mEsw-JhRlI/edit?usp=sharing
HI lisampederson,
#1. It seems like I forget to calculate rolling total, I modify my measure to change conditions, now it can be summarized based current year.
Total Attribute =
var currDate=MAX('Expand Table'[Detail Date])
return
CALCULATE (
SUM ( 'Expand Table'[Daily cost] ),
FILTER (
ALLSELECTED ( 'Expand Table' ),
[Detail Date] <= MAX ( [Detail Date] )
&& YEAR ( [Detail Date] ) = YEAR (currDate )
),
VALUES ( 'Calculator'[Unique Key] )
)
#2. Since I used original table to generate expand table, so if you direct create relationship between these table columns, it will return a 'circular dependency' error. In my opinion, you can try to create a bridge table with relationship key to link these tables.
Notice: Unique key is merged with project id and attribute column.
Regards,
Xiaoxin Sheng