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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
Anonymous
Not applicable

Custom Sort Logic for a drill down hierarchy

Hello,

I need to add a custom sort logic for a two-level drill-down hierarchy. Basically, the structure is similar to this
Category levels

|- IT 1 - Low

            - Medium

             -High

|- IT 2 - Low

            - Medium

             -High

|- IT 3 - Low

            - Medium

             -High

We have a bar chart which we drill down in hierarchy mode and we have turned off the concatenate option for x axis to have this nice view. 

sneharaina_0-1653316372705.png

Here the pink crossed out data labels are category level 1 data and blue ones are level 2 data. 

I wish to arrange it like LOW,MEDIUM,HIGH . If we sort by x axis, it can only sort alphabatically. So I created a lookup table which has a rank value like this

label_keyLabel ValueRank
it1_low              Low1
it1_medMedium2
it1_highHigh3
it2_lowLow4
it2_medMedium5
it2_highHigh6
it3_lowLow7
it3_medMedium8
it3_highHigh9

 

I followed this article,  but it doesn't seem to work. Rest all options that I explored are not for drilled down mode. They work for single value bar graph.

 

The issue we have is that the entries are repeated, hence we cannot sort the Label Value column based on rank.

 

Really appreciate any thoughts anyone has to solve this or even suggest a new approach to do this.

 

Thanks,

Sneha 

2 REPLIES 2
Anonymous
Not applicable

Thank you for your response. Yes, ideally that should work but it doesn't in my report. So as a work around I have added number prefixes for the field name, which is not neat but it works.

amitchandak
Super User
Super User

@Anonymous , Only have three values 1,2,3 low medium, and High

Then mark that as the sort column

 

Have two-column Axis, Sort on them expand-> Concatenate Label off

refer

Concatenate Label off : https://youtu.be/QgI0vIGIOOk

 

 

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

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