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

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
DataEnth
Regular Visitor

Dynamic order in stacked bar

Hi,

 

I need to show always other in the last regardless the values of Material compatible column. It's too complicated for me, I tried many option but always error, please help me.

DataEnth_1-1757260292484.png

 

I tried 

_Sir = IF(ISBLANK(dmt_ws_windows11[sir]),"Other",dmt_ws_windows11[sir])
 
Sort_Sir = IF(isblank(dmt_ws_windows11[Sir]),2,1)
 
and I sort _Sir by Sort_Sir but it doesn't work, any solution please?

 

 

1 ACCEPTED SOLUTION

Hi @DataEnth,

good. Then it should not be a problem. You need to create a column and sort the column "Sir" based on the values of that column. 

 

FBergamaschi_0-1757264267314.png

 

Here is my sample file to explain how I did that, Feel free to ask clarifications. You should include a column that specifies the sort order. I did that with Insert data, you can do as you prefer

 

https://drive.google.com/drive/folders/1oxe4dlkgSLIc5-_c3JMdILrA8z2GUMRo?usp=sharing

 

 

If this helped, please consider giving kudos and mark as a solution

@me in replies or I'll lose your thread

Want to check your DAX skills? Answer my biweekly DAX challenges on the kubisco Linkedin page

Consider voting this Power BI idea

Francesco Bergamaschi

MBA, M.Eng, M.Econ, Professor of BI

View solution in original post

10 REPLIES 10
v-hashadapu
Community Support
Community Support

Hi @DataEnth , Hope you're doing fine. Can you confirm if the problem is solved or still persists? Sharing your details will help others in the community.

v-hashadapu
Community Support
Community Support

Hi @DataEnth , hope you are doing great. May we know if your issue is solved or if you are still experiencing difficulties. Please share the details as it will help the community, especially others with similar issues.

v-hashadapu
Community Support
Community Support

Hi @DataEnth , Hope you're doing okay! May we know if it worked for you, or are you still experiencing difficulties? Let us know — your feedback can really help others in the same situation.

v-hashadapu
Community Support
Community Support

Hi @DataEnth , Thank you for reaching out to the Microsoft Fabric Community Forum.

 

I reproduced the scenario on my end using sample data and it worked successfully. To help you better understand the implementation, I’ve attached the .pbix file for your reference. Please take a look at it and let me know your observations.

 

Thank you for being part of the Microsoft Fabric Community!

Ashish_Mathur
Super User
Super User

Hi,

Share the download link of the PBI file.


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/
FBergamaschi
Solution Sage
Solution Sage

Hi @DataEnth,

can you please explain what you are asking? This sentence

 

I need to show always other in the last regardless the values.

 

is impossible to understand

 

What do you mean "last"? What do you mean "regardless of the values"?

 

Meanwhile, if you mean you want to group some values into a single label "others" (but you should specify how many you want to group there and based on what criteria), here is a solution to this problem (which might not be yours)

 

https://www.sqlbi.com/articles/showing-the-top-5-products-and-others-row/

 

 

 

If this helped, please consider giving kudos and mark as a solution

@me in replies or I'll lose your thread

Want to check your DAX skills? Answer my biweekly DAX challenges on the kubisco Linkedin page

Consider voting this Power BI idea

Francesco Bergamaschi

MBA, M.Eng, M.Econ, Professor of BI

 

 

I mean regardless the sort by "Materiel Compatible" , "Other" is a value from the column Sir. 

Are you trying to sort the categories in descending order based on the total value but  "other" should always be the last one?





Dane Belarmino | Microsoft MVP | Proud to be a Super User!

Did I answer your question? Mark my post as a solution!


"Tell me and I’ll forget; show me and I may remember; involve me and I’ll understand."
Need Power BI consultation, get in touch with me on LinkedIn or hire me on UpWork.
Learn with me on YouTube @DAXJutsu or follow my page on Facebook @DAXJutsuPBI.

hello, yes, correct. That's exactly what I'm looking for.

Hi @DataEnth,

good. Then it should not be a problem. You need to create a column and sort the column "Sir" based on the values of that column. 

 

FBergamaschi_0-1757264267314.png

 

Here is my sample file to explain how I did that, Feel free to ask clarifications. You should include a column that specifies the sort order. I did that with Insert data, you can do as you prefer

 

https://drive.google.com/drive/folders/1oxe4dlkgSLIc5-_c3JMdILrA8z2GUMRo?usp=sharing

 

 

If this helped, please consider giving kudos and mark as a solution

@me in replies or I'll lose your thread

Want to check your DAX skills? Answer my biweekly DAX challenges on the kubisco Linkedin page

Consider voting this Power BI idea

Francesco Bergamaschi

MBA, M.Eng, M.Econ, Professor of BI

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

December 2025 Power BI Update Carousel

Power BI Monthly Update - December 2025

Check out the December 2025 Power BI Holiday Recap!

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.