Forum Discussion
fxz9
8 years agoFrequent Visitor
table Calculate for sum field operation
Source Data Example item amount AA 10 AA 5 BB 3 BB 3 after powerBI by summrize by item (categray) item Sum AA 15 BB 6 I hope power bi can s...
- 8 years ago
Hi fxz9,
Power BI doesn't support that. As a workaround, you can show the difference in an extra column. Please refer to below measure:
AA-BB = CALCULATE ( SUM ( Table1[amount] ), FILTER ( ALL ( Table1 ), Table1[item] = "AA" ) ) - CALCULATE ( SUM ( Table1[amount] ), FILTER ( ALL ( Table1 ), Table1[item] = "BB" ) )Best regards,
Yuliana Gu
v-yulgu-msft
Microsoft Employee
8 years agoHi fxz9,
Power BI doesn't support that. As a workaround, you can show the difference in an extra column. Please refer to below measure:
AA-BB =
CALCULATE (
SUM ( Table1[amount] ),
FILTER ( ALL ( Table1 ), Table1[item] = "AA" )
)
- CALCULATE (
SUM ( Table1[amount] ),
FILTER ( ALL ( Table1 ), Table1[item] = "BB" )
)
Best regards,
Yuliana Gu
fxz9
8 years agoFrequent Visitor
Thanks for you replay