Dual - script and chart function
With the dual function it is possible to create arbitrary combinations of a number and a string.
Syntax:
Dual( s , x )
Forced association of an arbitrary string representation s with a given number representation x.
In Qlik Sense, all field values are potentially dual values. This means that the field values can have both a numeric value and a textual value. An example is a date that could have a numeric value of 40908 and the textual representation ‘2011-12-31’.
When several data items read into one field have different string representations but the same valid number representation, they will all share the first string representation encountered.
Tip noteThe dual function is typically used early in the script, before other data is read into the field concerned, in order to create that first string representation, which will be shown in filter panes.