Forum Discussion
Sorting Table Columns Based On Vaules
Hi all,
So I have a table and I would like to dynamically change the order of the columns based on the values in the top row.
So the table below:
| Test1 | Test2 | Test3 | Test4 | Test5 | Test6 | Test7 | Test8 | |
| 09/09/2017 | 18% | 0% | 14% | 11% | 0% | 0% | 11% | 0% |
| 16/09/2017 | 0% | 0% | 0% | 0% | 0% | 0% | 0% | 0% |
| 23/09/2017 | 17% | 3% | 3% | 0% | 0% | 0% | 0% | 0% |
| 30/09/2017 | 5% | 2% | 5% | 0% | 0% | 0% | 0% | 0% |
| 07/10/2017 | 17% | 3% | 4% | 0% | 0% | 0% | 0% | 0% |
| 14/10/2017 | 5% | 7% | 2% | 0% | 0% | 0% | 0% | 0% |
| 21/10/2017 | 15% | 5% | 3% | 0% | 0% | 0% | 0% | 0% |
| 28/10/2017 | 17% | 0% | 0% | 0% | 0% | 0% | 0% | 0% |
| 04/11/2017 | 1% | 2% | 1% | 0% | 0% | 0% | 0% | 0% |
| 11/11/2017 | 0% | 0% | 2% | 0% | 0% | 0% | 0% | 0% |
Would dynamically change to :
| Test1 | Test3 | Test4 | Test7 | Test2 | Test5 | Test6 | Test8 | |
| 09/09/2017 | 18% | 14% | 11% | 11% | 0% | 0% | 0% | 0% |
| 16/09/2017 | 0% | 0% | 0% | 0% | 0% | 0% | 0% | 0% |
| 23/09/2017 | 17% | 3% | 0% | 0% | 3% | 0% | 0% | 0% |
| 30/09/2017 | 5% | 5% | 0% | 0% | 2% | 0% | 0% | 0% |
| 07/10/2017 | 17% | 4% | 0% | 0% | 3% | 0% | 0% | 0% |
| 14/10/2017 | 5% | 2% | 0% | 0% | 7% | 0% | 0% | 0% |
| 21/10/2017 | 15% | 3% | 0% | 0% | 5% | 0% | 0% | 0% |
| 28/10/2017 | 17% | 0% | 0% | 0% | 0% | 0% | 0% | 0% |
| 04/11/2017 | 1% | 1% | 0% | 0% | 2% | 0% | 0% | 0% |
| 11/11/2017 | 0% | 2% | 0% | 0% | 0% | 0% | 0% | 0% |
Is this possible in Power BI?
Cheers,
Michael.
- Anonymous8 years ago
Anonymous,
It is not possible to dynamically change the order of the columns as you describe. In Query Editor, you can manually reorder the columns. Or you can create a table visual with the order you want.
Regards,
Lydia
2 Replies
- AnonymousNot applicable
Anonymous,
It is not possible to dynamically change the order of the columns as you describe. In Query Editor, you can manually reorder the columns. Or you can create a table visual with the order you want.
Regards,
Lydia- AnonymousNot applicable
Many thanks for your quick reply Lydia. As you propose I will manually sort the columns.