Forum Discussion
Table sorting in Power BI desktop
- 2 years ago
Hi,
Turns out that because I had another table in my data model that was using the same headers as this table, it was causing the conflict. I changed the table headers and it worked fine.
How I get around the same "null" values is by going into power query editor and then filtering those out, going back to DAX and then set the sort order before going into power query editor and removing the filter. It still keeps the same sort order then.
I didn't realise Power BI would consider a totally non-linked table to sort the current table but that was my issue and it is now resolved. Unfortunate that it took me almost an entire day to figure this out!
Hi, JS_UNI4C
I'm using the data provided by your picture in Power BI:
When I use the Level 1 order column to sort Level 1, I don't find any errors, as shown in the image below:
But when I use the Level 2 order to sort the Level 2 columns, I reproduce the problem:
For Level 2 columns, the column has multiple null values, and each null value corresponds to a different order, resulting in an error. You can right-click on your table and click on the copy table function to paste it into Excel, and then create a new table in Power BI to paste the table that from Excel. Level 1 is then re-ordered.
How to Get Your Question Answered Quickly
If it does not help, please provide more details with your desired output and pbix file without privacy information (or some sample data) .
Best Regards
Jianpeng Li
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
- JS_UNI4C2 years ago
Helper I
Hi,
Turns out that because I had another table in my data model that was using the same headers as this table, it was causing the conflict. I changed the table headers and it worked fine.
How I get around the same "null" values is by going into power query editor and then filtering those out, going back to DAX and then set the sort order before going into power query editor and removing the filter. It still keeps the same sort order then.
I didn't realise Power BI would consider a totally non-linked table to sort the current table but that was my issue and it is now resolved. Unfortunate that it took me almost an entire day to figure this out!
- Anonymous2 years agoNot applicable
Hi, JS_UNI4C
Thank you very much for your reply and the solution you shared. I think your solution is fantastic. You can mark your response as a solution to help others in the community find answers quickly when they encounter the same problem.
How to Get Your Question Answered Quickly
Best Regards
Jianpeng Li
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.