Forum Discussion
Matrix Table - Sorting by column, several KPI"s
- Anonymous1 year ago
Thanks for the reply from Jihwan_Kim , please allow me to provide another insight:
Hi, M_Chris
Indeed, as you mentioned, the sorting column must correspond one-to-one with the column being sorted.
Below is a screenshot from the official documentation for your reference:
Here’s a screenshot of the error I encountered:
I recommend using Power Query to regenerate a sorting column. Here’s my proposed solution:
1.First, group the necessary column to retain it and return the maximum value of the sorting column based on the grouping condition.
2.Next, sort the data in ascending order.
3.Insert an index column.
4.Expand the required columns and remove any unnecessary ones.
5.This should allow for proper sorting. Below is the final result, which I hope meets your expectations.
Can you share sample data and sample output in tabular format if I am misunderstanding? Or a sample pbix after removing sensitive data. We can better understand the problem and help you.
For questions about uploading data, you can try the following links:
How to provide sample data in the Power BI Forum - Microsoft Fabric Community
Solved: How to upload PBI in Community - Microsoft Fabric Community
Please find the attached pbix relevant to the case.
Best Regards,
Leroy Lu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Many thanks. The point is that my model is based on different sources which includes e.g. several times the KPI Profit on different positions with 20'. In my Key data sheet there should only appear one time the profit.
Result might just look like:
Orders 100'
Revenues 90'
Profit 20'
FCF 40'
If I try to apply the sorting column to the KPIs which I already have in my model then it gives me the error message that it is not possible as there is no 1-1 relation for KPI to Sorting (as KPI e.g. Profit is in different rows with diffeerent soring numbers due to several sources income statement and balance sheet for example).
- Anonymous1 year agoNot applicable
Thanks for the reply from Jihwan_Kim , please allow me to provide another insight:
Hi, M_Chris
Indeed, as you mentioned, the sorting column must correspond one-to-one with the column being sorted.
Below is a screenshot from the official documentation for your reference:
Here’s a screenshot of the error I encountered:
I recommend using Power Query to regenerate a sorting column. Here’s my proposed solution:
1.First, group the necessary column to retain it and return the maximum value of the sorting column based on the grouping condition.
2.Next, sort the data in ascending order.
3.Insert an index column.
4.Expand the required columns and remove any unnecessary ones.
5.This should allow for proper sorting. Below is the final result, which I hope meets your expectations.
Can you share sample data and sample output in tabular format if I am misunderstanding? Or a sample pbix after removing sensitive data. We can better understand the problem and help you.
For questions about uploading data, you can try the following links:
How to provide sample data in the Power BI Forum - Microsoft Fabric Community
Solved: How to upload PBI in Community - Microsoft Fabric Community
Please find the attached pbix relevant to the case.
Best Regards,
Leroy Lu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.