Controlling Locale, Language, and Encoding

The Batch Facility uses the locale of the server computer to do certain tasks correctly. For example, it uses locale for sort order and to select the appropriate decimal delimiter. In most cases, the Batch Facility will automatically detect the server's locale. Furthermore, the Batch Facility uses English as the default language for error messages and other output.

Starting with version 21, IBM® SPSS® Statistics operates in Unicode mode by default. Since the Batch Facility always starts in the default mode, this may affect existing jobs, since they started in code page mode in previous releases. Use the unicode switch to turn off Unicode mode and start jobs in code page mode.

You can override the default settings using the following command line switches:

Table 1. Switches for languages and locales
Switch Description
-LC_ALL locale Sets the locale for the Batch Facility. Use the appropriate locale name for your operating system.
  • On UNIX, you can get a list of locales that are available on your system by typing locale -a at the UNIX prompt.
  • On Windows, you can use the Regional and Language Options control panel to temporarily change to the locale you desire. Then issue the SHOW LOCALE command in the Batch Facility.
-language de|en|es|fr|it|ja|ko|pl|ru|zh_CN|zh_TW Sets the language for error messages and other output. You can choose from languages available in the IBM SPSS StatisticsServer installation directory on Windows or in the /bin subdirectory of the installation directory on UNIX.
-encoding windows Specifies an encoding subdirectory where error message and string table files are located. The encoding subdirectory is in the language subdirectory specified by -language. Currently, only Windows encoding is available.
-unicode on|off Turns Unicode mode on or off. The default is on. When Unicode mode is off, jobs run in code page mode, which is the current locale encoding. In releases previous to 21, Batch Facility jobs started in code page mode.
-codepageSyntaxFiles on|off ["encoding"] Controls the encoding used to read syntax files. The default is off. In the absence of an encoding identifier in the file or an encoding specification on INCLUDE or INSERT, syntax files are read as UTF-8 if –unicode yes or the current locale if –unicode no. If you specify -codepageSyntaxFiles on, all syntax files read in current locale encoding or the optional quoted code page encoding, regardless of encoding specified in the file or encoding specified on INCLUDE or INSERT. The quoted encoding value can be any valid code page encoding specification, including code page specifications listed in the file loclmap.xml, located in the installation directory, a numeric Windows code page value (for example, '1252'), or an IANA code page value (for example, 'iso8859-1' or cp1252).

Alternatively, if the Batch Facility doesn't detect the server's locale, try updating the Regional Options control panel on Windows.