The decimal separator defined replaces the decimal symbol set by your regional settings.
Qlik Sense automatically interprets text as numbers whenever a recognizable number pattern is encountered. The ThousandSep and DecimalSep system variables determine the makeup of the patterns applied when parsing text as numbers. The ThousandSep and DecimalSep variables set the default number format pattern when visualizing numeric content in front-end charts and tables. That is, it directly impacts the Number formatting options for any front end expression.
Assuming a thousand separator of comma ‘,’ and a decimal separator of ‘.’, these are examples of patterns that would be implicitly converted to numeric equivalent values:
These are examples of patterns that would remain unchanged as text; that is, not converted to numeric:
|Set DecimalSep='.';||Sets ‘.’ as the decimal separator.|
|Set DecimalSep=','; <![CDATA[ ]]>||Sets ‘,’ as the decimal separator.|
Unless otherwise specified, the examples in this topic use the following date format: MM/DD/YYYY. The date format is specified in the SET DateFormat statement in your data load script. The default date formatting may be different in your system, due to your regional settings and other factors. You can change the formats in the examples below to suit your requirements. Or you can change the formats in your load script to match these examples.
Default regional settings in apps are based on the regional system settings of the computer or server where Qlik Sense is installed. If the Qlik Sense server you are accessing is set to Sweden, the Data load editor will use Swedish regional settings for dates, time, and currency. These regional format settings are not related to the language displayed in the Qlik Sense user interface. Qlik Sense will be displayed in the same language as the browser you are using.
Example – Effect of setting number separator variables on different input data
Open the Data load editor and add the load script below to a new tab.
The load script contains:
A dataset of sums and dates with the sums set in different format patterns.
A table named Transactions.
The DecimalSep variable which is set to ‘.’.
The ThousandSep variable which is set to ','.
The delimiter variable that is set as the '|' character to separate the different fields in a line.
Set ThousandSep=','; Set DecimalSep='.'; Transactions: Load date, id, amount as amount Inline [ date|id|amount 01/01/2022|1|1.000-45 01/02/2022|2|23.344 01/03/2022|3|4124,35 01/04/2022|4|2431.36 01/05/2022|5|4,787 01/06/2022|6|2431.84 01/07/2022|7|4132.5246 01/08/2022|8|3554.284 01/09/2022|9|3.756,178 01/10/2022|10|3,454.356 ] (delimiter is '|');
Load the data and open a sheet. Create a new table and add this field as a dimension: amount.
Create this measure:
Any value not interpreted as number remains as text and is aligned to the left by default. Any successfully converted values are aligned to the right, retaining the original input format.
The expression column shows the numeric equivalent, which is by default formatted with only a decimal separator ‘.’. This can be overridden with the Number formatting drop down setting in the expression configuration.