Skip to main content
Announcements
Join us at Qlik Connect for 3 magical days of learning, networking,and inspiration! REGISTER TODAY and save!
cancel
Showing results for 
Search instead for 
Did you mean: 
jagan
Luminary Alumni
Luminary Alumni

Sorting the dates in x-axis

I have dates in the following format like

d-4 28-Jan

d-3 29-Jan

d-2 30-Jan

d-1 31-Jan

d0 1-Feb

d1 2-Feb

d2 3-Feb

How to arrange dates in this order in x-axis, i used both the sort by number and text, but the order is changed.

11 Replies
johnw
Champion III
Champion III

Ah, OK. It looks like the issue is that your TransMonth is currently just a text field, where I'd guessed it was a month() field. How about this?

date(date#(TransMonth&TransYear,'MMMYYYY'),'MMM YYYY') as TransMonthYear

Also, you might want to turn your TransMonth into a month() instead of text, which will let it sort properly in your list box and charts:

month(date#(TransMonth&TransYear,'MMMYYYY')) as TransMonth

Not applicable

Thanks John... perfect timing 5:30 on Friday afternoon and all my graphs now display in the right order...

Job done... Smile Thanks again!!! Mike