Skip to main content
Announcements
Join us on Sept. 17 to hear how our new GenAI Assistant empowers data professionals: REGISTER
cancel
Showing results for 
Search instead for 
Did you mean: 
jmialoundama
Specialist
Specialist

DUAL REPLACE NUMBER BY TEXT

I am using an extension which allows me to display the values ​​of my column.

Capture.JPGI

have a column called Level which contains numbers from 1 to 6.

I would like to replace these figures with text for example if it is 1 then we put Lvl.1, if it is 2 then we put Lv.2

I was told about the DUAL function on Qlik Sense which allows you to do this.
I would like to have more details, thank you

Labels (2)
2 Replies
martinpohl
Partner - Master
Partner - Master

hello,

the dual function allows you to give text a numeric value.

best example is month

jan = 1

feb = 2

oct = 10

So you see name of month but it is sorted by the numeric value

In script you can use it like

dual(text field,number field) as fieldname

All dual values are aligned like a number field to right instead of text fields aligned to the left by default

Regards

jmialoundama
Specialist
Specialist
Author

Hi , 

 

Thanks you for you answer. 

 

So in my case if I want to change the "1" of my DEPTH fields to "Lvl 1", what will it do in my script?