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

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.

Reply
Anonymous
Not applicable

Sort a line chart by the Y axis in Power BI

Hello,

 

I am trying to visualize some data on a graphic. I need to show some values according to the depth that is on the y-axis.

I have followed the instructions of the page below:

https://www.daytodatastuff.co.uk/blog/sort-a-line-chart-by-the-y-axis-in-power-bi

 

I sorted in power query the list according to depth and then added an index column and then tried to sort my values by Index. I still get the same error: We can’t sort the 'Verschiebung' column by 'Index'. There can't be more than one value in 'Index' for the same value in 'Verschiebung'.

 

I have to mention though that my 'Verschiebung' column was generated in DAX and not in the power Query, so when I want to transform the data in Power query, I do not see the column 'Verschiebung'.

But honestly, I do not think this should be a problem because, the calculated column 'Verschiebung' follows the rows of column 'depth' which is existing in power query.

 

Can you help me here?

 

Thank you for your time and consideration.

Best regards,

Maya Elias

1 ACCEPTED SOLUTION
Anonymous
Not applicable

Hi @Anonymous 

Please make sure the column in Axis doesn't have same value.

My Sample:

1.png

I add PSI in Axis in line chart. When I try to sort PSI by Index, it will show the same error.

2.png

I try to remove same value in PSI.

3.png

I can sort PSI column by Index.

4.png

Best Regards,

Rico Zhou

 

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

View solution in original post

2 REPLIES 2
Anonymous
Not applicable

Hi @Anonymous 

Please make sure the column in Axis doesn't have same value.

My Sample:

1.png

I add PSI in Axis in line chart. When I try to sort PSI by Index, it will show the same error.

2.png

I try to remove same value in PSI.

3.png

I can sort PSI column by Index.

4.png

Best Regards,

Rico Zhou

 

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

Anonymous
Not applicable

Hello,

 

Thank you for your reply.

This is what I ended up doing but I was trying to find another way without the need of manipulating my data. Apparently it is the only way possible.

 

Best regards,

Yushi

Helpful resources

Announcements
July 2025 community update carousel

Fabric Community Update - July 2025

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

July PBI25 Carousel

Power BI Monthly Update - July 2025

Check out the July 2025 Power BI update to learn about new features.