Forum Discussion
Sort slicer by column
Hi everyone,
I have created a slicer that lists the study names I have loaded in power bi. I'm trying to sort the slicer using a column within the table used to build the slicer called 'id'.
For that purpose, I have gone to the modelling tab and selected the 'id' column and click sort by column. However it seems the slicer is not affected and still shows the items alphabetically. Also, the tables are in direct query mode, in case it makes any difference.
Can anyone please help me ?
thanks a lot in advance!
Best regards
Laura
hi LauraBueno
For your case, you should selected "study names" filed then click sort by column and choose 'ID'.
By the way, here is a blog for you refer to:
https://radacad.com/sort-by-column-in-power-bi
Regards,
Lin
5 Replies
- amitchandakSuper User
LauraBueno , As long both column as same granularity you can do
https://docs.microsoft.com/en-us/power-bi/desktop-sort-by-column
I have done for Direct query :https://community.powerbi.com/t5/Community-Blog/Decoding-Direct-Query-in-Power-BI-Part-1-Time-Intelligence-in/ba-p/922885
- LauraBuenoHelper III
Hi amitchandak ,
Thank you for your message. However, I still have the same issue.
For the first link you shared, I dont see the option of "sort by" within the slicer, maybe that works only for certain graphs?
As for the second link, I had already created a column and used it to sort the entire table using that column however the slicer doesn't seem to be affected by it and still displays the items alphabetically.
Any ideas of how to make it work?
thanks
Laura
- v-lili6-msftCommunity Support
hi LauraBueno
For your case, you should selected "study names" filed then click sort by column and choose 'ID'.
By the way, here is a blog for you refer to:
https://radacad.com/sort-by-column-in-power-bi
Regards,
Lin