Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.
Dears
I have a simple table as below and I would need to calculate (create new calculated column?)
when Amount for Cost centers A, B, C remain as is, but Amount for cost center D (Service Common) is split between Cost centers A, B, C by 1/3.
Could you please help?
Thank you very much!
Period | Cost center | Service | Amount | New amount |
March | A | Purchasing | xx | xx + 1/3 of CC D |
March | B | Accounting | xx | xx + 1/3 of CC D |
March | C | Controlling | xx | xx + 1/3 of CC D |
March | D | Common | xx | - |
HI @KatkaS ,
You could try the following dax to create a new column:
amount2 =
var test3=CALCULATE(VALUES('Table'[Amount])/3,FILTER(ALL('Table'),'Table'[Cost center]="D"))
var TEST2= IF('Table'[Cost center]="A"||'Table'[Cost center]="B"||'Table'[Cost center]="C",'Table'[Amount]+test3,'Table'[Amount])
RETURN TEST2
And final :
Wish it is helfpul for you!
Best Regards
Lucien
@KatkaS , Try a column like
new column =
var _1 = sumx(filter(Table, Table[Cost] = "D" && [Period] =earlier([Period]) && [Service] = "Common"),[Amount])
return
if(Table[Cost] in {A,B,C}, _1/3, Blank())
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
102 | |
101 | |
78 | |
69 | |
63 |
User | Count |
---|---|
141 | |
106 | |
101 | |
85 | |
72 |