Skip to main content
Woohoo! Qlik Community has won “Best in Class Community” in the 2024 Khoros Kudos awards!
Announcements
Nov. 20th, Qlik Insider - Lakehouses: Driving the Future of Data & AI - PICK A SESSION
cancel
Showing results for 
Search instead for 
Did you mean: 
jleberre
Contributor II
Contributor II

Coloring by dimension and ordering legend

Hello

In a bar chart, I order dimension using expression like this : if(Match(mydimension,'US'),1,if(Match(mydimension,'FR'),2, ...))

It works fine.

But when I configure color by dimension using 'mydimension', the different values of mydimension are listed in alphabetical order, and no more using expression.

Any idea to resolve this problem?

Thanks!

1 Reply
jleberre
Contributor II
Contributor II
Author

I finally resolved my problem using Dual(text,number) function

My field has  now 2 values: a string value for display purposes, and a number value for sorting purposes

Dimension is ordered by number instead of by expression