Check your eligibility for this 50% exam voucher offer and join us for free live learning sessions to get prepared for Exam DP-700.
Get StartedDon't miss out! 2025 Microsoft Fabric Community Conference, March 31 - April 2, Las Vegas, Nevada. Use code MSCUST for a $150 discount. Prices go up February 11th. Register now.
Hello all,
I have two matrix visualizations like this,
The values for both the matrix visuals are taken from a single table.
I want to subtract the values of both the sub-totals. But, keeping the 1st matrix's total as it is, say 190 and I want to select a range and sum the values, for example, for the account numbers 4 to 6, the summed up values will be 10+20+30 = 60.
Then, I need to subtract the 190 (Sum of Matrix 1) with 60 (Sum of Matrix 2).
190 - 60 = 130.
Finally, that result 130 should be displayed in the 2nd Matrix itself or another matrix.
How can I achieve this?
I tried to achieve this with a slicer, it is not working as I expected. Could anyone please help to resolve this?
Sample Files are given below,
Thanks in Advance,
Praveen.
Solved! Go to Solution.
@Anonymous try this:
Total Difference = CALCULATE( SUM(Table[Amount]), ALL( Table ) )
-
CALCULATE(
SUM(Table[Amount]),
Table[Account] IN {4,5,6}
)
Subscribe to the @PowerBIHowTo YT channel for an upcoming video on List and Record functions in Power Query!!
Learn Power BI and Fabric - subscribe to our YT channel - Click here: @PowerBIHowTo
If my solution proved useful, I'd be delighted to receive Kudos. When you put effort into asking a question, it's equally thoughtful to acknowledge and give Kudos to the individual who helped you solve the problem. It's a small gesture that shows appreciation and encouragement! ❤
Did I answer your question? Mark my post as a solution. Proud to be a Super User! Appreciate your Kudos 🙂
Feel free to email me with any of your BI needs.
Table[Account] >= 4 && Table[Account] <= 6
replace the IN condition with above logic to check the range.
Subscribe to the @PowerBIHowTo YT channel for an upcoming video on List and Record functions in Power Query!!
Learn Power BI and Fabric - subscribe to our YT channel - Click here: @PowerBIHowTo
If my solution proved useful, I'd be delighted to receive Kudos. When you put effort into asking a question, it's equally thoughtful to acknowledge and give Kudos to the individual who helped you solve the problem. It's a small gesture that shows appreciation and encouragement! ❤
Did I answer your question? Mark my post as a solution. Proud to be a Super User! Appreciate your Kudos 🙂
Feel free to email me with any of your BI needs.
@Anonymous so if i understood your requirement correctly , you want to subtract value of selected account (in a slicer) from total amount, correcT?
Subscribe to the @PowerBIHowTo YT channel for an upcoming video on List and Record functions in Power Query!!
Learn Power BI and Fabric - subscribe to our YT channel - Click here: @PowerBIHowTo
If my solution proved useful, I'd be delighted to receive Kudos. When you put effort into asking a question, it's equally thoughtful to acknowledge and give Kudos to the individual who helped you solve the problem. It's a small gesture that shows appreciation and encouragement! ❤
Did I answer your question? Mark my post as a solution. Proud to be a Super User! Appreciate your Kudos 🙂
Feel free to email me with any of your BI needs.
@Anonymous is this range fixed? Always 4 to 6?
Subscribe to the @PowerBIHowTo YT channel for an upcoming video on List and Record functions in Power Query!!
Learn Power BI and Fabric - subscribe to our YT channel - Click here: @PowerBIHowTo
If my solution proved useful, I'd be delighted to receive Kudos. When you put effort into asking a question, it's equally thoughtful to acknowledge and give Kudos to the individual who helped you solve the problem. It's a small gesture that shows appreciation and encouragement! ❤
Did I answer your question? Mark my post as a solution. Proud to be a Super User! Appreciate your Kudos 🙂
Feel free to email me with any of your BI needs.
@Anonymous try this:
Total Difference = CALCULATE( SUM(Table[Amount]), ALL( Table ) )
-
CALCULATE(
SUM(Table[Amount]),
Table[Account] IN {4,5,6}
)
Subscribe to the @PowerBIHowTo YT channel for an upcoming video on List and Record functions in Power Query!!
Learn Power BI and Fabric - subscribe to our YT channel - Click here: @PowerBIHowTo
If my solution proved useful, I'd be delighted to receive Kudos. When you put effort into asking a question, it's equally thoughtful to acknowledge and give Kudos to the individual who helped you solve the problem. It's a small gesture that shows appreciation and encouragement! ❤
Did I answer your question? Mark my post as a solution. Proud to be a Super User! Appreciate your Kudos 🙂
Feel free to email me with any of your BI needs.
Thank you very much for your kindl response. But, if this range is high, say for instance if I have to select the values between the ranges of 40000 to 90000 out of 1 million accounts, how can I select, what could be the DAX for selecting this kind of ranges?
Regards,
Praveen.
Table[Account] >= 4 && Table[Account] <= 6
replace the IN condition with above logic to check the range.
Subscribe to the @PowerBIHowTo YT channel for an upcoming video on List and Record functions in Power Query!!
Learn Power BI and Fabric - subscribe to our YT channel - Click here: @PowerBIHowTo
If my solution proved useful, I'd be delighted to receive Kudos. When you put effort into asking a question, it's equally thoughtful to acknowledge and give Kudos to the individual who helped you solve the problem. It's a small gesture that shows appreciation and encouragement! ❤
Did I answer your question? Mark my post as a solution. Proud to be a Super User! Appreciate your Kudos 🙂
Feel free to email me with any of your BI needs.
Awesome!!! Thank You very much.
Regards,
Praveen.
Yes this range is fixed.
Hi Parry,
No. The slicer one is the example which i have tried myself. The actual requirement is, I need to subtract between both the matrices subtotal.
1st matrix values are as it is coming from the source.
2nd matrix's value should be a range of selected values using DAX. say for ex,the sum of values of account numbers 4 to 6.
Sum of 1st matrix - sum of 2nd matrix (with the selected Range of values) = Result should be displayed on the second matrix.
190 - 60 = 130
Thanks for your reply,
Praveen.
March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount! Prices go up Feb. 11th.
Check out the January 2025 Power BI update to learn about new features in Reporting, Modeling, and Data Connectivity.
User | Count |
---|---|
146 | |
87 | |
66 | |
52 | |
46 |
User | Count |
---|---|
215 | |
90 | |
83 | |
66 | |
58 |