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

Grow your Fabric skills and prepare for the DP-600 certification exam by completing the latest Microsoft Fabric challenge.

Reply
bcastillo
Frequent Visitor

Issues sorting quarters and year

Hello,

 

I am having issues sorting the x-axis data on a line chart in order, when I try to convert the column for quarterly data I receive an error message.

 

example2.PNG    

 

 

 

examples.PNG

 

 

 

 

screenshot2.PNG

1 ACCEPTED SOLUTION
edhans
Super User
Super User

Add a new field to your date table that would be numeric data. 201801, 201802, 201803, etc. for the quarters. Then have simlar text field in your date table that would convert to text, so it shows as you have it - Q2-17, Q3-17, etc.

 

Now use the new text string of quarters (q2-17) in your visuals, then in the modeling tab and use the SORT BY feature, sort those by the numeric quarter numbers above (201801, 201802, etc).  That is easiest to do in the table view.image.png



Did I answer your question? Mark my post as a solution!
Did my answers help arrive at a solution? Give it a kudos by clicking the Thumbs Up!

DAX is for Analysis. Power Query is for Data Modeling


Proud to be a Super User!

MCSA: BI Reporting

View solution in original post

4 REPLIES 4
edhans
Super User
Super User

Add a new field to your date table that would be numeric data. 201801, 201802, 201803, etc. for the quarters. Then have simlar text field in your date table that would convert to text, so it shows as you have it - Q2-17, Q3-17, etc.

 

Now use the new text string of quarters (q2-17) in your visuals, then in the modeling tab and use the SORT BY feature, sort those by the numeric quarter numbers above (201801, 201802, etc).  That is easiest to do in the table view.image.png



Did I answer your question? Mark my post as a solution!
Did my answers help arrive at a solution? Give it a kudos by clicking the Thumbs Up!

DAX is for Analysis. Power Query is for Data Modeling


Proud to be a Super User!

MCSA: BI Reporting

Wow. Finally got perfect solution.

IT WORKED! Thank you!

Excellent!



Did I answer your question? Mark my post as a solution!
Did my answers help arrive at a solution? Give it a kudos by clicking the Thumbs Up!

DAX is for Analysis. Power Query is for Data Modeling


Proud to be a Super User!

MCSA: BI Reporting

Helpful resources

Announcements
RTI Forums Carousel3

New forum boards available in Real-Time Intelligence.

Ask questions in Eventhouse and KQL, Eventstream, and Reflex.

MayPowerBICarousel

Power BI Monthly Update - May 2024

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