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

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.

Reply
benqpbi
Helper I
Helper I

How to Sort in order correctly in visual

benqpbi_0-1669014708263.png

 

Why i am unable to sort in order of number 1 to 14, kindly help me on this.
thanks

1 ACCEPTED SOLUTION
Jihwan_Kim
Super User
Super User

Hi,

One of ways to solve this is to create names like below.

 

Category
SEQ01
SEQ02
SEQ03
SEQ04
SEQ05
SEQ06
SEQ07
SEQ08
SEQ09
SEQ10
SEQ11
SEQ12
SEQ13
SEQ14

 


If this post helps, then please consider accepting it as the solution to help other members find it faster, and give a big thumbs up.


Click here to visit my LinkedIn page

Click here to schedule a short Teams meeting to discuss your question.

View solution in original post

9 REPLIES 9
Jayee
Responsive Resident
Responsive Resident

Hi @benqpbi 

 

Use column from example  transformation in power query and enter the number for each row what is the number you have after SEQ and power query will add all the rows and use the out put to sort by other columns.

 

https://learn.microsoft.com/en-us/power-query/column-from-example

 

Here the sample file

 

If this post helps, then please consider Accept it as the solution, Appreciate your Kudos!!

Jayee
Responsive Resident
Responsive Resident

@benqpbi 

 

Did you check the sample file provided in the above reply

 

please check here the link again

Jihwan_Kim
Super User
Super User

Hi,

One of ways to solve this is to create names like below.

 

Category
SEQ01
SEQ02
SEQ03
SEQ04
SEQ05
SEQ06
SEQ07
SEQ08
SEQ09
SEQ10
SEQ11
SEQ12
SEQ13
SEQ14

 


If this post helps, then please consider accepting it as the solution to help other members find it faster, and give a big thumbs up.


Click here to visit my LinkedIn page

Click here to schedule a short Teams meeting to discuss your question.

can i create a calculated column the full name looks like

abc_prog_gig_seq1
till
abc_prog_gig_seq17

 

will switch( true(), ) work ? 

thank you 🙂

Hi,

Creating calculated column might be not efficient.

Please try changing a name in the source.

Or,

Please try chaging a name in Power Query Editor.

 

Please be noted that try using 01 02 03 04 05 ....  not  1 2 3 4 5....


If this post helps, then please consider accepting it as the solution to help other members find it faster, and give a big thumbs up.


Click here to visit my LinkedIn page

Click here to schedule a short Teams meeting to discuss your question.

ryan_mayu
Super User
Super User

@benqpbi 

you can create a sort column and sort by the created column

pls see the offical article below

https://learn.microsoft.com/en-us/power-bi/create-reports/desktop-sort-by-column

 





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

Proud to be a Super User!




i did but my power query sorts correctly but in visual it is different and when i try to sort by creating index i get this error any ideas

benqpbi_0-1669032488507.png

 

that's because for the same task name, you have more than one myorder value. you have to make sure the relationship between these two columns is one to one.





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

Proud to be a Super User!




Helpful resources

Announcements
July 2025 community update carousel

Fabric Community Update - July 2025

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

July PBI25 Carousel

Power BI Monthly Update - July 2025

Check out the July 2025 Power BI update to learn about new features.