3
votes

I am pretty new with Power BI (Desktop) and I have a basic question. I have searched Power BI books and sites for a solution, but I could not find it so far.

The purpose of my dashboard is to present the result of an employee survey. There are about 30 questions, with multiple questions going from 1 (strongly disagree) to 5 (strongly agree). The questions are divided into 5 different sections. There is a slicer used to select the section under review, and the average of survey responses to each question is then shown on a clustered bar chart, compared to average and other measures like number of respondents.

The issue is that I would like to have the questions appearing on the clustered bar chart in the same order as in the inquiry, and I don’t manage to solve this. Questions are always sorted on my chart either alphabetically, either based on the average response score… I tried to add an index in the table with the questions, but I can’t figure out how to sort my question on the chart on that index…

Any suggestion appreciated, Thanks

Fred

Complement info after first answer (thanks for your help!).

My model is built in Power BI desktop. The list of questions, with their index, is in a DIM_table called DIM_Questions list. The answers to the questions, of which the average value is presented on the chart, are in a FACT_table called FACT_Responses. There is a relation between the two tables with a field called QuestionID

I did the sort in the modelling section of Power BI, but on the DIM_Questions List table. Could that be the issue? Sort in modelling

The result on the chart is still that questions are sorted on alphabetical order. chart sorted

Thank you for your help!

1
are you using SSAS to build your model or is all of your data consolidated within the .pbix file?StelioK
I am using Power BI desktop to build my model.FredC
Please ensure that the Qnr column is a numeric type and not a 'text' data type.StelioK
Qnr is a Decimal number, as you can see in the screen shot above. Could it be that the chart takes the data from one table, but the order of the questions from another?FredC
Please ensure the format is set to 'Whole Number' and not 'General'StelioK

1 Answers

2
votes

If you are using power bi to model your data just click on the column you need sorted, then go to the 'Modeling' tab and select the 'Sort by column' option, then just select which column you'd like to sort by, please ensure that the column you are sorting by is numeric.

If you are using SSAS you will need to select the column to sort by in the properties pane, please see the image below:

enter image description here