Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Random Sorting

Dear Community,

again i've got some rather easy looking question which i can't solve.

In a bar chart i want to sort the main dimension "randomly" (e.g.: 2006 2008 2007 2005). How can i use this sorting option?

I tried it with a set analysis, but it doesnt work.

Thanks in advance for any help.

regards

donuteater

1 Solution

Accepted Solutions
CELAMBARASAN
Partner - Champion
Partner - Champion

Hi,

     Try with this expression in sort by expression option.

     =match(YearField,'2006','2008','2007','2005')

Celambarasan

View solution in original post

3 Replies
CELAMBARASAN
Partner - Champion
Partner - Champion

Hi,

     Try with this expression in sort by expression option.

     =match(YearField,'2006','2008','2007','2005')

Celambarasan

Not applicable
Author

// solved

This formular works pretty well, but still i've got a problem with some of my calculations.

in some Diagrams with a YearEndEstimate-formula the Dimension is sorted totally weird.

I get results like 'Mae','Jan','Aug'

although i applied the proper sorting via the match() formular.

What does the match formula do?

--

problem was caused by different naming of columns (Mae <> Mrz)

Thanks for you profund help! 🙂

rbecher
MVP
MVP

The match function performs a case sensitive comparison and returns the found position.

BTW, this is not a random sorting because of the literal years-list. If you need a real random sorting just use the random function as sort expression:

=rand()

- Ralf

Astrato.io Head of R&D