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.
Our requirement is pretty simple and I am not sure how to achieve this in Power BI. We need to display a measure in the form of a bar graph with a producing facility on the X-Axis. We want to show the bar graphs in a particular order of producing facility and NOT sorted by the displayed measure. I am unable to achieve this in Power BI. I have 2 tables, one fact table and another dimensional table that contains producing facilities which includes a sort order (numeric value). I add the sort order, producing facility as my X-axis. The graph displays fine in order, however, the producing facility does NOT show up on my X-axis, only the sort order. How can I display the Producing Facility on my X-axis?
TIA
Hi jagannathan,
Instead of Sort Order in the X Axis, put Producing Facility there. Then, in the visual, select Sort By Producing Facility.
It will sort according to your predefiend sort order. It worked for me:
Let me know if it works.
It doesn't work. For instance, here's a summary of my data as an example
Producing Facility | #OfUnits |
ABC | 1 |
ZYZ | 20 |
EFG | 5 |
XYZ | 9 |
Dimensional table for Sort Order
Producing Facility | Sort Order |
XYZ | 1 |
ABC | 2 |
ZYZ | 3 |
EFG | 4 |
Bar graph should display #OfUnits in the "Sort Order"
I think it worked if the picture below is how you wich to see the results.
After creating the visual, go to the table to the right, select the Producing facility column, then in the ribbon, select column tools, Sort by and select Sort order column.
Hope it works!
Hi MrKrikausk - That helps. However, since I am using SQL Server views and NOT tables, the column sort options don't show up. I guess that is the problem. I will have to convert the views into Tables and give it a try
Hi @Anonymous ,
Are you connecting to SSAS?
You have to sort this in SSAS model itself as live connection does not have the ability to perform sorting.
Best Regards,
Liang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
@Anonymous , I am sure that you have done two-steps.
1. Mark sort column. Sort Order is Sort column of Facility
2. From three dots you have chosen facility as the sort column
https://docs.microsoft.com/en-us/power-bi/desktop-sort-by-column
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
111 | |
96 | |
80 | |
68 | |
59 |
User | Count |
---|---|
150 | |
119 | |
104 | |
87 | |
67 |