Forum Discussion
Sort on Matrix with unpivot data?
Hi! Is there a way I can sort by a row? Below is a Matrix row example:
(Gross Sales, Profit, HR are value type. The numbers are the value and the Brands are brand field)
| Brand A | Brand B | Brand X |
Gross Sales | 10 | 33 | 42 |
Profit | 422 | 30 | 90 |
HR | 53 | 53 | 35 |
I want to sort by the Profit row so It should look like the below order? Is there any way to achieve this (the data is unpivoted and won’t work if I pivot it since I want the data to appear in this same exact format)
| Brand B | Brand X | Brand A |
Gross Sales | 33 | 42 | 10 |
Profit | 30 | 90 | 422 |
HR | 53 | 35 | 53 |
You can accomplish this by making a matrix visual with your 3 measures in the values area, and in the format option choose "Show on Rows" in Values area. Put your Brand column as the column headers, and then use the Ellipsis in upper right of the matrix to Sort by Profit.
If this works for you, please mark it as solution. Kudos are appreciated too. Please let me know if not.
Regards,
Pat
2 Replies
- mahoneypatMicrosoft Employee
You can accomplish this by making a matrix visual with your 3 measures in the values area, and in the format option choose "Show on Rows" in Values area. Put your Brand column as the column headers, and then use the Ellipsis in upper right of the matrix to Sort by Profit.
If this works for you, please mark it as solution. Kudos are appreciated too. Please let me know if not.
Regards,
Pat
- powerbihelp87Helper V
such an easy fix, don't know why I never use this without transforming everything! Thanks so much