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
srivatsan34
Frequent Visitor

Re arraging existing columns in chart

BI Issue.JPG

 

I am currently using Power BI desktop trial version and when visualising bard charts using excel data, i am unable to re arrange the x-axis in oorder of 10 9 8 7 5. Is it possible to re arrange it in trial version or do we need access to the full version to modify the chart.

1 ACCEPTED SOLUTION
MFelix
Super User
Super User

Hi @srivatsan34,

 

 

What is happening is that the column that you are using for the axis is formatted as text so when you added it to your chart it will give you 10, 5, 7, 8, 9 you need to format the column to number and chose the sort order to Z-A and it will be in the correct format

 

Order.png

 

 

Regards

MFelix


Regards

Miguel Félix


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

Proud to be a Super User!

Check out my blog: Power BI em Português



View solution in original post

3 REPLIES 3
MFelix
Super User
Super User

Hi @srivatsan34,

 

 

What is happening is that the column that you are using for the axis is formatted as text so when you added it to your chart it will give you 10, 5, 7, 8, 9 you need to format the column to number and chose the sort order to Z-A and it will be in the correct format

 

Order.png

 

 

Regards

MFelix


Regards

Miguel Félix


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

Proud to be a Super User!

Check out my blog: Power BI em Português



Hi @MFelix Thank you for your help. What if the column i currently use contains both text and values? So do i need to duplicate this coloumn and format one columna as text and the other column as number?

Hi @srivatsan34,

 

Add a new column with the following code:

 

Sort_Order =
IF (
    NOT ( ISERROR ( 'Table'[Column] + 0 ) )
        = TRUE ();
    CONCATENATE ( REPT ( 0; 4 - LEN ( 'Table'[Column] ) ); 'Table'[Column] );
    'Table'[Column]
)

 

This will convert all your number to 0 added format 10 will become 0010

 

Regards,

MFelix

 


Regards

Miguel Félix


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

Proud to be a Super User!

Check out my blog: Power BI em Português



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.