Qlik Community

Ask a Question

New to Qlik Sense

If you’re new to Qlik Sense, start with this Discussion Board and get up-to-speed quickly.

Announcements
QlikWorld Online 2021, May 10-12: Our Free, Virtual, Global Event REGISTER TODAY
cancel
Showing results for 
Search instead for 
Did you mean: 
mnvrma
Partner
Partner

Sorting

mnvrma_0-1614770641985.png

I'm showing the last 12 months' data and I'm using wildmatch statement with the Month field in the sorting.

" WildMatch(Month,'Mar','Apr','May','Jun','Jul','Aug','Sep','Oct','Nov','Dec','Jan','Feb') "

I have to change this statement for the upcoming month.

is it possible to do sorting in other method or with any new field?

3 Replies
Chanty4u
Champion III
Champion III

it will come automatically right?

In the sort tab mark the expression and write the expression as given below :

if(wildmatch(Month,'Mar'),1,if(wildmatch(Month,'Apr',2,if(wildmatch(Month,'May'),3,if(wildmatch(Month,'Jun'),4)))))

 

or

You can try a sort expression like

= match(Month,''Mar','Apr','May','Jun','Jul','Aug','Sep','Oct','Nov','Dec','Jan','Feb')

like that do for all. and change accordingly

Or
Master
Master

Wouldn't it make more sense to use the full month (e.g. Mar 21, Feb 22)? That would auto-sort correctly, instead of trying to force-sort the month names. You can still elect to only display the month name by formatting it as 'mmm', but you'd be using MonthName(Date) instead of Month(Date) to get your field.

raghuchowdary
Contributor II
Contributor II

Hi,

did you try just giving  your 'Date' field in the sorting expression.