Forum Discussion
Sorting Numbers from 1 - 50
Hi guys,
Just want to know how to properly sort this numbering in Power BI (table chart)
Thank you
Hi rquizon09,
What you need is a second column in your table that is just the number, formatted as a whole number. Then you can sort this Question No column by that new column.
Please let me know if you need more guidance.
----------------------------------
If this post helps, please consider accepting it as the solution to help other members find it quickly. Also, don't forget to hit that thumbs up and subscribe! (Oh, uh, wrong platform?)P.S. Need a more in-depth consultation for your Power BI data modeling or DAX issues? Feel free to hire me on Upwork or DM me directly on here! I would love to clear up your Power BI headaches.
4 Replies
- Wilson_Memorable Member
Hi rquizon09,
What you need is a second column in your table that is just the number, formatted as a whole number. Then you can sort this Question No column by that new column.
Please let me know if you need more guidance.
----------------------------------
If this post helps, please consider accepting it as the solution to help other members find it quickly. Also, don't forget to hit that thumbs up and subscribe! (Oh, uh, wrong platform?)P.S. Need a more in-depth consultation for your Power BI data modeling or DAX issues? Feel free to hire me on Upwork or DM me directly on here! I would love to clear up your Power BI headaches.
- Wilson_Memorable Member
rquizon09,
One way would be to create a new column in Power Query that replaces "ItemNo." with "", then converting the column to a whole number.
Jihwan_Kim shows that below as well.
- Jihwan_KimSuper User
Hi,
one of ways is to create a sort order column in power query editor.
Please check the below picture and the attached pbix file.
let Source = Data_source, #"Duplicated Column" = Table.DuplicateColumn(Source, "Question No.", "sort order"), #"Replaced Value" = Table.ReplaceValue(#"Duplicated Column","ItemNo.","",Replacer.ReplaceText,{"sort order"}), #"Changed Type" = Table.TransformColumnTypes(#"Replaced Value",{{"sort order", Int64.Type}}) in #"Changed Type"