Forum Discussion
Noob101
4 years agoNew Member
Change column calculation
I have data with calculated columns in power bi, but I need to change one of the values in the calculation from a certain point, without it affecting the previous data within that same column. Is thi...
- 4 years ago
There is only one formula per column. It isn't like Excel where you can specify rows for different formulas.
You could change the formula to be the below, which would use your old formula on or before June 15, 2022, and the new formula if it is after June 15, 2022.
VAR varOldFormula = PutYourOldFormulaHere VAR varNewFormula = PutYourNewFormulaHere RETURN IF( TableName[Date] > DATE(2022,6,15), varNewFormula, varOldFormula )
edhans
4 years agoCommunity Champion
There is only one formula per column. It isn't like Excel where you can specify rows for different formulas.
You could change the formula to be the below, which would use your old formula on or before June 15, 2022, and the new formula if it is after June 15, 2022.
VAR varOldFormula = PutYourOldFormulaHere
VAR varNewFormula = PutYourNewFormulaHere
RETURN
IF(
TableName[Date] > DATE(2022,6,15),
varNewFormula,
varOldFormula
)