Skip to main content
Announcements
Have questions about Qlik Connect? Join us live on April 10th, at 11 AM ET: SIGN UP NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Month sort order on chart with input date range

I have a bar chart with month on x axis and Sum(sales) on y axis.I can sort the chart by fiscal month order or calendar month order.However, when I select the date range from say nov-2011 to jul-2012,my chart does not show Nov through Jul .It either shows Apr -May-Jun-Jul-Nov-Dec-Jan-Feb-Mar(Fiscal sort order) or jan-Feb-Mar-Apr-May-Jun-Jul-Nov-Dec(Caledar month sort order).I want it to show Nov-Dec-Jan-Feb-Mar-Apr-May-Jun-Jul. I have tried load order etc with no luck.Help please.

8 Replies
Gysbert_Wassenaar

You seem to have a month-year field. Try sorting your month dimension in the chart by expression and choose your month-year field as expression. See attached example. If that doesn't work then your month-year field isn't a date. In that case create it as a date formatted as month-year: date(monthstart(MyDateField),'MMM-YYYY') as Month-Year


talk is cheap, supply exceeds demand
Not applicable
Author

Thanks for the reply.I tried the method suggested above but I am getting some weird sorting for my date range filters.I have attached the qvw.I really appreciate the help.

This is the first time I am uploading a qlikview document.I hope you can see the data.Please let me know if I need to provide any additional info.

Not applicable
Author

I already tried calendarmonth field and it does not work.The qlikview file I attached has the date formatting around calendarmonth but I also tried just plain calendar month and still doesn't work.

Edited to add: In the attached qlikview,if I remove the list box selection and just use the input date range,I get distorted month sort order aven if I use calendar month.

Gysbert_Wassenaar

You already have a field you can use: CalendarMonth. Use this field name for the sort expression.

comm84707.png

See this tutorial for using calendar objects to make date selections.


talk is cheap, supply exceeds demand
Not applicable
Author

The CalendarMonth sort works with the list box selection but if I clear the list box and use the input date range filter,the sorting is off again

Not applicable
Author

Sir,

I have created 2 separate list box

1) Month

2) Year

Month is like Jan,Feb, Mar,...

Year 2013,2014..

Requirement is like

I can select multiple month range among year.

And I want to display that range in chart title

Like Nov-13 to Mar-14.

Not applicable
Author

I have created 2 separate list box

1) Month

2) Year

Month is like Jan,Feb, Mar,...

Year 2013,2014..

Requirement is like

I can select multiple month range among year.

And I want to display that range in chart title

Like Nov-13 to Mar-14.

Not applicable
Author

hey Swapna,

additionally you can sort by "Numeric Value" the Sort Tab; this might resolve your problem. Tks,