cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
Helper II
Helper II

Subtraction in PowerBi matrix Aggregation

Hello,

I have a table with the following contents:


Header Subheader Subheader2 Amount
     A            B                C               10
     A            B                D               20


This is then represented as a power bi matrix:

 

Header   Amount
     A          30
       B        30
         C      10
         D      20


I have a situation which requires the aggregation to roll up to a subtraction rather than an addition. So the value of B should be C - D (10 - 20) instead of (C + D) without reversing the sign of D. So the matrix should look like:

 

Header   Amount
    A           -10
      B         -10
        C        10
        D        20

 

Any DAX measure I can create to achieve this?

1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted
Microsoft
Microsoft

Re: Subtraction in PowerBi matrix Aggregation

Hi @apollo89,

 

I'm afraid such a requirement cannot be achieved now. As the values shown in Subtotal row are always aggregated by SUM by default. We are not able to change this behavior now.

1.PNG

 

Regards,

Yuliana Gu

Community Support Team _ Yuliana Gu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

1 REPLY 1
Highlighted
Microsoft
Microsoft

Re: Subtraction in PowerBi matrix Aggregation

Hi @apollo89,

 

I'm afraid such a requirement cannot be achieved now. As the values shown in Subtotal row are always aggregated by SUM by default. We are not able to change this behavior now.

1.PNG

 

Regards,

Yuliana Gu

Community Support Team _ Yuliana Gu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

Helpful resources

Announcements
Super Users of the Quarter - Q2 2020

Super Users of the Quarter - Q2 2020

Who are our Super User Superstars? Who made it to the top of the leaderboards? Get the answers!

June 2020 Community Highlights

June 2020 Community Highlights

Featured community members, changes to the Community, and more! Read up on recent Power BI community news.

Community Summit North America

Community Summit North America

Innovate, Collaborate, Grow. The top training and networking event across the globe for Microsoft Business Applications

Power Platform 2020 release wave 2 plan

Power Platform 2020 release wave 2 plan

Features releasing from October 2020 through March 2021

Top Kudoed Authors