Forum Discussion
Tmk123
Helper II
2 years agoAggregate a calculated column
Hi, I am having trouble aggregating a calculated column correctly. My calculated column is below. My goal is for it to add all the Amounts for each Catalog # for the year 2022. It is actu...
FreemanZ
Super User
2 years agoHi Tmk123 ,
Not sure if i fully get you.
try to plot a slicer with division column and table visual with catelog column and a measure like:
Amt 2022 =
CALCULATE(
SUM(data[Invoice Amt]),
data[Year]=2022
)
it worked like:
- Tmk1232 years ago
Helper II
Thanks, that is what I am trying to do, however, received a circular dependency error.
A circular dependency was detected: _Sum Sales By Div[_Amt % Change], _Sum Sales By Div[_2022 Invoice Amt], _Sum Sales By Div[_Amt % Change].
This is the updated column, based on your suggestion:
_2022 Invoice Amt =CALCULATE(SUM('_Sum Sales By Div'[Invoice Amt]),'_Sum Sales By Div'[Year] = 2022)I had another calculated column calculating the % Change. I cannot use measures in my table because I have a slicer controlling the % Change. Is there a way to rewrite this to fix the circular dependency?
_Amt % Change = DIVIDE([_2023 Annualized Amt] - [_2022 Invoice Amt], [_2022 Invoice Amt])