Get certified for free when you join Fabric Data Days 2026 and dive into Fabric, Power BI, SQL, AI, and other essential data skills.
Join nowJuly 7 - July 17 | Round 2 of the Power BI Dataviz World Championships. Don't miss your chance! Learn more
Hello,
I currently have - hopefully - a small challenge. My matrix visual is defined to be sorted by rows. Now I have a field that names the columns from another table where the values are summed and counted. Now, I also want to dynamically sort the columns by the highest values of the summation.
how cani solve the use case?
Thanks a lot for upcoming Support!
Solved! Go to Solution.
Hi @CJ-Flag ,
If you are trying to sort the columns based on the following total value.
1. first you can create a calculated column to get the total value.
Column =
CALCULATE (
SUM ( financials[ Sales] ),
FILTER (
ALL ( financials ),
'financials'[Month Name] = EARLIER ( 'financials'[Month Name] )
)
)
2. Then create a calculation table and create a one-to-many relationship with the original table.
Table =
SUMMARIZE('financials','financials'[Month Name],'financials'[Column])
3. Make the month name column in the calculation table sorted according to the column column.
4. Place the corresponding fields in the matrix.
If your Current Period does not refer to this, please clarify in a follow-up reply.
Best Regards,
Clara Gong
If there is any post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi @CJ-Flag ,
If you are trying to sort the columns based on the following total value.
1. first you can create a calculated column to get the total value.
Column =
CALCULATE (
SUM ( financials[ Sales] ),
FILTER (
ALL ( financials ),
'financials'[Month Name] = EARLIER ( 'financials'[Month Name] )
)
)
2. Then create a calculation table and create a one-to-many relationship with the original table.
Table =
SUMMARIZE('financials','financials'[Month Name],'financials'[Column])
3. Make the month name column in the calculation table sorted according to the column column.
4. Place the corresponding fields in the matrix.
If your Current Period does not refer to this, please clarify in a follow-up reply.
Best Regards,
Clara Gong
If there is any post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi @CJ-Flag,
Matrix rows can be sorted by a value field as below:
Please note that sorting will be applied to the totat and there's no option to sort it by the individual column field value (jul, aug, sep, etc).
Hello,
thank you very much for your reponse.
You are right but u are changing the sorting of the rows.
the rows have to fix, so a,b,c or 1,2,3
and depending on that the columns have to been sorted depending on the sum of the values.
u have a hint how to solve this?
To dynamically sort columns in a Power BI matrix visual by the highest values of a summation, you can follow these steps:
TotalValue = SUM('YourTable'[YourValueColumn])
ColumnRank =
RANKX(
ALLSELECTED('YourColumnTable'[YourColumn]),
[TotalValue],
,
DESC,
DENSE
)
Join us in Barcelona for FabCon and SQLCon, the Fabric, Power BI, SQL, and AI community event. Save €200 with code FABCMTY200.
Join Data Days 2026: 60 days of free live/on-demand sessions, challenges, study groups, and certification opportunities.
| User | Count |
|---|---|
| 29 | |
| 28 | |
| 27 | |
| 27 | |
| 19 |
| User | Count |
|---|---|
| 56 | |
| 47 | |
| 39 | |
| 28 | |
| 21 |