Qlik Community

Qlik GeoAnalytics Discussions

Discussion Board for collaboration regarding Qlik GeoAnalytics.

annie8099
New Contributor II

Straight table sort

How can I sort a dimension in a straight table alphanumerically?  Currently, it sorts in "natural order" which is not what we need. We have an item number field that contains letters and numbers.  For example, Item number "30A" is ordered before item number "11B".  The application we use is Qlik Sense.  What do I need to order our item numbers in an alphanumeric order using Qlik Sense 3.2?

Tags (1)
1 Solution

Accepted Solutions

Re: Straight table sort

This seems like the right sorting (when used descending) based on what I found here:

The Alphabetizer sorts any list in alphabetical order...and much more!

Capture.PNG

11 Replies
kenphamvn
Contributor III

Re: Straight table sort

Hi

In sort property chose "Sort alphabetically"

8-22-2017 14-34-48.jpg

annie8099
New Contributor II

Re: Straight table sort

Add the number 110D to your example and you will get

05C

11B

30A

110D

This is incorrect for an alphabetical sort.

Qlik uses a "natural sort", you can lookup information on Natural sort if you are unfamiliar with it.

I am trying to get the field to override Qlik's natural sort option and sort alphanumerically. 

Any help with this is greatly needed. 

Re: Straight table sort

When you add 110D, what do you expect the order of the above 4 numbers to be?

annie8099
New Contributor II

Re: Straight table sort

I expect the order to be:

05C

11B

110D

30A

Re: Straight table sort

Not the same as what you wanted, but this gives a slightly different sort...

Capture.PNG

felipedl
Valued Contributor III

Re: Straight table sort

Hi Ann,

You can use the dual() function, making a new "order" in a way you see fit.

Only problem is, that you would need to specify the numeric order for all the data.

Example:

=ValueList(dual('05C',1),dual('11B',2),dual('110D',3),dual('30A',4))


Gives the following as it's ordered by the new numeric representation.

Sample.png

Re: Straight table sort

This seems like the right sorting (when used descending) based on what I found here:

The Alphabetizer sorts any list in alphabetical order...and much more!

Capture.PNG

annie8099
New Contributor II

Re: Straight table sort

I will look into the rank() function and let you know if it's what we need.

It looks interesting.  Thank you, I'll get back.

Re: Straight table sort

Sounds good

Community Browser