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

Earn the coveted Fabric Analytics Engineer certification. 100% off your exam for a limited time only!

Reply
Anonymous
Not applicable

Custom sorting for slicer not working

I am currently generating a time intelligence table using DAX and I am intending to sort the period in a particular order. The period contains things such as this week, this month, last month and last week.

 

During the generation of the table I also added an order column which ranges from 1 to 5 which was intended to sort the period labels.

 

I have went into the data modeller selected the order column and sorted by that column I also sorted descending on the order column however none of this is translating to the report. It continues to sort by the period name.

 

There are no sorting filters on the slicer either

 

Am I missing something that is causing this sort to fail?

1 ACCEPTED SOLUTION
AlB
Super User
Super User

@Anonymous 

In the file you uploaded, the column Period was NOT sorted using the column Order in the "Time Intelligence" table. I simply did that and it works fine, as expected. See it at work in the attached file.

AlB_0-1606576297672.png

Please mark the question solved when done and consider giving a thumbs up if posts are helpful.

Contact me privately for support with any larger-scale BI needs, tutoring, etc.

Cheers 

SU18_powerbi_badge

View solution in original post

7 REPLIES 7
AlB
Super User
Super User

@Anonymous 

In the file you uploaded, the column Period was NOT sorted using the column Order in the "Time Intelligence" table. I simply did that and it works fine, as expected. See it at work in the attached file.

AlB_0-1606576297672.png

Please mark the question solved when done and consider giving a thumbs up if posts are helpful.

Contact me privately for support with any larger-scale BI needs, tutoring, etc.

Cheers 

SU18_powerbi_badge

Anonymous
Not applicable

Thanks, I made a stupid rookie error by thinking the "Sort by column" applied to the entire table rather than to each column!

v-robertq-msft
Community Support
Community Support

Hi, @Anonymous 

According to your description, I guess you want to make the visual in your report sorted by [Order] column, you don’t need to sort the data in Power query editor, you can just simpy achieve it in the visual setting, like this:

v-robertq-msft_0-1606464306727.png

 

 

If you don’t mean this, you can post some sample data(without sensitive data) and your expected result.

How to Get Your Question Answered Quickly 

 

Best Regards,

Community Support Team _Robert Qin

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Anonymous
Not applicable

Hi

 

I have added the PBIX file above, I am trying to order a slicer in a particular order however even adding in an "Order" column to the table does not seem to do the trick

Anonymous
Not applicable

I can't share the original but I will try and make a version of it replicating the issue.

AlB
Super User
Super User

Hi @Anonymous 

Can you share the pbix?

Please mark the question solved when done and consider giving a thumbs up if posts are helpful.

Contact me privately for support with any larger-scale BI needs, tutoring, etc.

Cheers 

SU18_powerbi_badge

Anonymous
Not applicable

Hi, 

 

I have made a dummy PBIX file which replicates the same issue which can be found here

 

From the below screenshot you can see the order isnt ideal, jumping from Yesterday to This Month then back to Last Week etc..

PBIDafty_0-1606569586707.png

Within the Data Modeler you will see there is an "Order" column and it should be sorting my that however it doesnt seem to translate to the slicer

Helpful resources

Announcements
April AMA free

Microsoft Fabric AMA Livestream

Join us Tuesday, April 09, 9:00 – 10:00 AM PST for a live, expert-led Q&A session on all things Microsoft Fabric!

March Fabric Community Update

Fabric Community Update - March 2024

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