Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
dgonda
Helper I
Helper I

Is there a way to sort by column headers in a matrix?

Hi,

So as the title would suggest, because of column header translating reasons, I had to use a matrix instead of a table for some data, but the matrix doesn't sort the values if I click on a column header. Is there a way to achieve this?

1 ACCEPTED SOLUTION
v-yetao1-msft
Community Support
Community Support

Hi @dgonda 

You can use an custom column to order your columns . We can do that with following steps. Assuming we have a table like below.

(1)We can add a reverse index.

Ailsamsft_0-1626329279399.jpegAilsamsft_1-1626329279405.jpeg

(2) Close and apply Query Editor, select the Type column and make it sort by column of Index.

Ailsamsft_2-1626329279407.jpeg

(3) Now the order of the column heads will follow the Index.

Ailsamsft_3-1626329279409.jpeg

(4) If you want to put it in a custom order, you can customize the index yourself. For example, you can create a conditional column in Query Editor.

Ailsamsft_4-1626329279411.jpegAilsamsft_5-1626329279412.jpeg

Best Regards

Community Support Team _ Ailsa Tao

 

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

1 REPLY 1
v-yetao1-msft
Community Support
Community Support

Hi @dgonda 

You can use an custom column to order your columns . We can do that with following steps. Assuming we have a table like below.

(1)We can add a reverse index.

Ailsamsft_0-1626329279399.jpegAilsamsft_1-1626329279405.jpeg

(2) Close and apply Query Editor, select the Type column and make it sort by column of Index.

Ailsamsft_2-1626329279407.jpeg

(3) Now the order of the column heads will follow the Index.

Ailsamsft_3-1626329279409.jpeg

(4) If you want to put it in a custom order, you can customize the index yourself. For example, you can create a conditional column in Query Editor.

Ailsamsft_4-1626329279411.jpegAilsamsft_5-1626329279412.jpeg

Best Regards

Community Support Team _ Ailsa Tao

 

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.