Forum Discussion
Sum up hierarchy not working (with sample)
- 2 years ago
hi MagikJukas
Please see if this is what you want, As the below post said, I wonder why would you do that.
Measure 2 = SWITCH(TRUE(),ISINSCOPE(Forecast[Material]), ABS(([FCST Acc.])-CALCULATE([FCST Acc.],REMOVEFILTERS(Forecast[Series],Forecast[Material]))))Measure 3 =VAR _SelSeries = SELECTEDVALUE(Forecast[Series])VAR _FCSTAccTotal = CALCULATE([FCST Acc.],REMOVEFILTERS(Forecast[Series],Forecast[Material]) )VAR _Sum = SUMX(VALUES(Forecast[Material]), ABS([FCST Acc.] - _FCSTAccTotal) )RETURN SWITCH(TRUE(),NOT(ISINSCOPE(Forecast[Material])) && ISINSCOPE(Forecast[Series]), _Sum) - 2 years ago
Hello talespin
thanks for your reply.
Indeed, your solution work with the sample I provided.
However, when testing in the original dataset, it was not working.
the solution was to change
REMOVEFILTERS(Forecast[Series],Forecast[Material])
with
REMOVEFILTERS(Forecast[Material]),ALLSELECTED(Forecast))
By doing so, the measure keeps the selected filters expect for the Material, which is what I wanted.
thanks!
hi MagikJukas
Please see if this is what you want, As the below post said, I wonder why would you do that.
- MagikJukas2 years ago
Resolver III
Hello talespin
thanks for your reply.
Indeed, your solution work with the sample I provided.
However, when testing in the original dataset, it was not working.
the solution was to change
REMOVEFILTERS(Forecast[Series],Forecast[Material])
with
REMOVEFILTERS(Forecast[Material]),ALLSELECTED(Forecast))
By doing so, the measure keeps the selected filters expect for the Material, which is what I wanted.
thanks!