Forum Discussion
Creating a new calculated column makes an existing calculated column blank
- 2 years ago
Hi RingoMoon - Hope you have first created the prior year column then key column.You can check the dependency view in Power BI to see how columns are dependent on each other.
Slight modification in Prior Key calculation:
Prior Year =
VAR CurrentYear = 'Events'[EventEditionCode]
VAR EventName = 'Events'[EventName]
RETURN
CALCULATE(
MAX('Events'[EventEditionCode]),
FILTER(
'Events',
'Events'[EventName] = EventName &&
'Events'[EventEditionCode] < CurrentYear &&
NOT(ISBLANK('Events'[Revenue]))
)
)Now define your key column :
key =
CONCATENATE(
'Events'[EventName],
'Events'[EventEditionCode]
)try the above calculation and make sure the key column and prior key columns are not dependant each other (circular dependency). Hope it works . please try
Did I answer your question? Mark my post as a solution! This will help others on the forum!
Appreciate your Kudos!!
Hi RingoMoon - Hope you have first created the prior year column then key column.You can check the dependency view in Power BI to see how columns are dependent on each other.
Slight modification in Prior Key calculation:
Prior Year =
VAR CurrentYear = 'Events'[EventEditionCode]
VAR EventName = 'Events'[EventName]
RETURN
CALCULATE(
MAX('Events'[EventEditionCode]),
FILTER(
'Events',
'Events'[EventName] = EventName &&
'Events'[EventEditionCode] < CurrentYear &&
NOT(ISBLANK('Events'[Revenue]))
)
)
Now define your key column :
key =
CONCATENATE(
'Events'[EventName],
'Events'[EventEditionCode]
)
try the above calculation and make sure the key column and prior key columns are not dependant each other (circular dependency). Hope it works . please try
Did I answer your question? Mark my post as a solution! This will help others on the forum!
Appreciate your Kudos!!