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
Anttonen
Frequent Visitor

Multible column sorting problem

Hi,

 

I'm having a problem with multiple column sorting. In this case the dataset is about 100 000 row which I want sort based on 3 columns. In all columns that are used for sorting the data type is text and format as follows (1234_1_1; 5678; 1). When I apply the sort, the it is not as expected. However, if I take an small subset of the data sorting works as expected. Sorting with the whole dataset works correctly also in Excel. The first sorting column (1234_1_1) is concatenated, however, even if do the sorting based on the original values (numbers as text) the sorting fails. Result is the same if I change the data type as numbers. Any ideas? Example what I'm hoping to get below.

 

Thank you

 

Mikko

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

1 ACCEPTED SOLUTION

Thanks for your reply. I did some futher tests and the Power Query sorting works. The reason for sorting is to do data clening using "remove dublicates" after this. However, even if the sortig works on the Power Query side the rows are not sorted as expected in the Data view with this data set. Not sure if Power Query sorting should affect the data view but it would be very strange if not.

View solution in original post

4 REPLIES 4
v-juanli-msft
Community Support
Community Support

Hi @Anttonen 

As tested, it works on my side.

Capture1.JPG

Please tell me what's wrong on your side and what's your expected result.

 

Best Regards
Maggie
Community Support Team _ Maggie Li
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

 

Thanks for your reply. I did some futher tests and the Power Query sorting works. The reason for sorting is to do data clening using "remove dublicates" after this. However, even if the sortig works on the Power Query side the rows are not sorted as expected in the Data view with this data set. Not sure if Power Query sorting should affect the data view but it would be very strange if not.

Anttonen
Frequent Visitor

Capture.PNG

Anonymous
Not applicable

Hi @Anttonen,

 

Try splitting col1 into 3 columns with "_" as the delimiter and then sort the table on the basis of the 5 columns.

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.

Top Solution Authors
Top Kudoed Authors