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

Get certified in Microsoft Fabric—for free! For a limited time, the Microsoft Fabric Community team will be offering free DP-600 exam vouchers. Prepare now

Reply
odraode_
Frequent Visitor

Date Table and Bar chart sorting

Hello to everyone,

I created a data table in my report since I want to follow PBI best practises but I have to say I don't see any benefits using it.

 

One of the issue is the following one: once created the data table, the date hierarchy disappear and even tough I created my own hierarchy it doesn't seem as powerful as the previous one. For example this is the bar chart with custom date hierarchy:

 

odraode__0-1685468616352.png

I couldn't find a way to sort it properly, while it was quite easy with the previous date hierarchy:

odraode__1-1685468751366.png

 

Can someone help me on sorting it out?

 

Thank you!

 

 

1 ACCEPTED SOLUTION

I upload an example pbix here: https://file.io/xuQARjwJTpIQ.

I'm unable to sort the bar chart below (using data table) while I can easily sort the one above (without using data table).

 

Thank you for your help!

View solution in original post

3 REPLIES 3
vanessafvg
Super User
Super User

its really impossible to help you with what you have provided.  please can you share your pbix?  and can you show how you have set up your date table?  

 

also what are you expecting, why is one better than the other, please provide enough information to assist.  





If I took the time to answer your question and I came up with a solution, please mark my post as a solution and /or give kudos freely for the effort 🙂 Thank you!

Proud to be a Super User!




I upload an example pbix here: https://file.io/xuQARjwJTpIQ.

I'm unable to sort the bar chart below (using data table) while I can easily sort the one above (without using data table).

 

Thank you for your help!

hi there, the issue is that you are using the month name  column on the date hierarchy, but month name is a string, not a number, and so you have to tell power bi how to sort the month name .   

 

See file attached but what I did was on the month name column in the date 2 table i set the month name to use the month column to sort, so that it understood the order i expect, and that sorted the issue out. 

 

vanessafvg_0-1685557735149.png

 





If I took the time to answer your question and I came up with a solution, please mark my post as a solution and /or give kudos freely for the effort 🙂 Thank you!

Proud to be a Super User!




Helpful resources

Announcements
Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount! Early Bird pricing ends December 9th.

Nov PBI Update Carousel

Power BI Monthly Update - November 2024

Check out the November 2024 Power BI update to learn about new features.

October NL Carousel

Fabric Community Update - October 2024

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