Environment variables precedence example

The following table shows the current setting of the environment variables and the effect of calling setlocale(LC_ALL,""). The last column indicates the locale setting after setlocale(LC_ALL,"") is called.

Table 1. Environment variables precedence example
Environment Variable and Category Names Value of Environment Variables Value of Category after Call to setlocale (LC_ALL,"")
LC_COLLATE de_DE de_DE
LC_CTYPE de_DE de_DE
LC_MONETARY en_US en_US
LC_NUMERIC (unset) da_DK
LC_TIME (unset) da_DK
LC_MESSAGES (unset) da_DK
LC_ALL (unset) (not applicable)
LANG da_DK (not applicable)