z/OS UNIX System Services User's Guide
Previous topic | Next topic | Contents | Contact z/OS | Library | PDF


Examples: Changing locale

z/OS UNIX System Services User's Guide
SA23-2279-00

For example, say that you are using OMVS, the 3270 terminal interface. If your /etc/csh.login is not set up for your locale and LANG, then in order to work in a locale such as Danish, you should add this to your .login file:
tty -s
set tty_rc=$status
if (($?LOCALE_SWITCH == 0 ) && ($tty_rc == 0)) then
        echo "------------------------------------------------"
        echo "- Logon shell will now be invoked to reflect   -"
        echo "- code page IBM-277                            -"
        echo "------------------------------------------------"
        setenv LOCALE_SWITCH EXECUTED
        setenv LANG C
        setenv LC_ALL Da_DK.IBM-277
        # Issue chcp if not using OMVS command
        if ($?_BPX_TERMPATH != "OMVS"  ) then
          chcp -a ISO8859-1 -e IBM-277
        endif
        exec tcsh -l
endif
unset tty_rc

If you want your messages displayed in a different language than that specified in the system-wide /etc/csh.login, you have to modify your .login accordingly.

For a list of the z/OS UNIX locales (and their locale object names) and locale source files, see Locale objects, source files, and charmaps.

Go to the previous page Go to the next page




Copyright IBM Corporation 1990, 2014