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

Earn the coveted Fabric Analytics Engineer certification. 100% off your exam for a limited time only!

Reply
rrhascall
Helper II
Helper II

Sorting

Hello,

Hoping someone can please advise.

Is there a way to deactivate or remove the sorting on a visual or matrix?  My dataset is sorted the way I would like to see it, however, when I create a visual, it uses the my row or column fields as sorts by default and ignores the sorting of my dataset.  I would like to try and avoid putting my preferred sort value under Tooltips just so I can sort results correctly.

2 ACCEPTED SOLUTIONS

You have to create a Sort By column. For example, if you have a file with Jan, Feb, Mar, Apr, it will not sort by month date, but alphabetically, so Apr, Feb, Jan, Mar. Useless. You want Jan to sort by 1, Feb by 2, Mar, by 3, etc.

 

So create a column in your data set that has the desired sort you want. You have to create the column. You cannot sort your data and expect that to work. It won't.

 

Then use the Sort By Columns functionality. See this article for details.



Did I answer your question? Mark my post as a solution!
Did my answers help arrive at a solution? Give it a kudos by clicking the Thumbs Up!

DAX is for Analysis. Power Query is for Data Modeling


Proud to be a Super User!

MCSA: BI Reporting

View solution in original post

dax
Community Support
Community Support

Hi @rrhascall , 

The viusal will sort by the columns in visual, so if you want to sort visual by specific in dataset, you need to set sort by in model like below

572.PNG

 Then whe you use name column in visual, which will sort it by sort column.

Best Regards,
Zoe Zhi

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

10 REPLIES 10
Tad17
Solution Sage
Solution Sage

Hey @rrhascall 

 

In the PBIX file:

 

1. Go to the Data view

2. Go to the Modelling tab

3. Click on the column you wish to sort

4. Click the "Sort by Column" buttom in the ribbon and sort to your hearts content. 

 

This sets the default sort pattern for that column even when it is used in visuals.

Appreciate the quick reply but as mentioned in my original post, i already have my dataset sorted via the method you outlined.  The issue is my visual includes sorting by default based on the fields that I'm using and ignores my dataset sorting.  I don't see away to remove the sorting from the visual itself.

@rrhascall 

 

I'm afraid you either have to use the sort by function, create a sort by column as @edhans  suggested, or simply resort to clicking the header of the column on the matrix to sort it. If you need it sorted an unorthodox way then creating a sort by column is your only method. You will need to create the sort by column for your "Rows" in the Matrix to get it to work properly.

You have to create a Sort By column. For example, if you have a file with Jan, Feb, Mar, Apr, it will not sort by month date, but alphabetically, so Apr, Feb, Jan, Mar. Useless. You want Jan to sort by 1, Feb by 2, Mar, by 3, etc.

 

So create a column in your data set that has the desired sort you want. You have to create the column. You cannot sort your data and expect that to work. It won't.

 

Then use the Sort By Columns functionality. See this article for details.



Did I answer your question? Mark my post as a solution!
Did my answers help arrive at a solution? Give it a kudos by clicking the Thumbs Up!

DAX is for Analysis. Power Query is for Data Modeling


Proud to be a Super User!

MCSA: BI Reporting

The sort column is already in my dataset.  It is a numerical value and it is how I would like the data to be sorted.  The visual I have created is ignoring this and only allows me to sort by the fields included in the visual.  This is what I'm trying to resolve.

Hello, 

 

Have you already sorted your category column by your sort column? If so and the visual still ignores this sort, what visual are you using? 






Did I answer your question? Mark my post as a solution!

Proud to be a Super User!




"Tell me and I’ll forget; show me and I may remember; involve me and I’ll understand."
Need Power BI consultation, get in touch with me on LinkedIn or hire me on UpWork.
Learn with me on YouTube @DAXJutsu.

The Matrix visual lacks functionality.  There are lots of ideas on the community site.  Below are the front runners.  Please vote these up!

https://ideas.powerbi.com/forums/265200-power-bi-ideas/suggestions/11185431-add-a-multiple-columns-s...

https://ideas.powerbi.com/forums/265200-power-bi-ideas/suggestions/17401381-conditional-formatting-f...

dax
Community Support
Community Support

Hi @rrhascall , 

The viusal will sort by the columns in visual, so if you want to sort visual by specific in dataset, you need to set sort by in model like below

572.PNG

 Then whe you use name column in visual, which will sort it by sort column.

Best Regards,
Zoe Zhi

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


@rrhascall wrote:

The sort column is already in my dataset.  It is a numerical value and it is how I would like the data to be sorted.  The visual I have created is ignoring this and only allows me to sort by the fields included in the visual.  This is what I'm trying to resolve.


What happened when you made it a "Sort By Column" per the article I linked to? 

 

This feature really does work. I use it daily. We are trying to help you with how the product works.



Did I answer your question? Mark my post as a solution!
Did my answers help arrive at a solution? Give it a kudos by clicking the Thumbs Up!

DAX is for Analysis. Power Query is for Data Modeling


Proud to be a Super User!

MCSA: BI Reporting

So in a round about way that I don't like or recommend, if you are having this issue and the sort by function is not working the last resort is to include the sort by column in hte visual, click the column header to sort by it, and then change the font color to match the background.

 

I would go through the data and sort each column by the numerical sort column just to make sure first. Again, if your first column (the Row headers) are not sorted by the numerical sort column then it won't work in a matrix visual.

Helpful resources

Announcements
April AMA free

Microsoft Fabric AMA Livestream

Join us Tuesday, April 09, 9:00 – 10:00 AM PST for a live, expert-led Q&A session on all things Microsoft Fabric!

March Fabric Community Update

Fabric Community Update - March 2024

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