You can use the default locale on your operating system, or explicitly set a locale for use by the Sybase IQ components on your machine.
Setting the Sybase IQ locale on a computer
If the default locale is appropriate for your needs, you do not need to take any action.
To find out the default locale of your operating system, see “Determining locale information”.
If you need to change the locale, you can set either or both of the SALANG and SACHARSET environment variables:
SACHARSET=charset;SALANG=language_code
where charset is a valid character set label and language_code is a language code from the list of language label values in “Understanding the locale language” in SQL Anywhere Server – Database Administration > Configuring Your Database > International languages and character sets > Understanding locales.
To set environment variables on different operating systems, see Chapter 1, “File Locations and Installation Settings,” in Reference: Building Blocks, Tables, and Procedures.
Setting the locale for an INSERT...LOCATION statement
When the database uses a non-default locale for your platform, you must set an environment variable on the local client in order for Sybase IQ to load the correct information for language, collation sequence, character set, and date/time format.
When determining the locale name, Sybase IQ first checks for the value of the LC_ALL environment variable. If LC_ALL is not set, Sybase IQ uses the value of the LANG environment variable. If neither variable is set, Sybase IQ uses the “default” entry in the locales file.
Open the $SYBASE/locales/locales.dat file in a text editor. For example:
locale = default, us_english, roman8 locale = C, us_english, roman8 locale = american, us_english, roman8 locale = english.iso88591, us_english, iso_1
Set the LC_ALL or LANG environment variable to the correct value. If on the platform in step 1, your database’s collation is iso_1 and you are using English, then you need to set the value of the environment variable LC_ALL or LANG to “american.iso88591”. Otherwise, Sybase IQ will use the locale name “default” which has collation “roman8”.
For example, in the sh or ksh shells:
LC_ALL= american.iso88591;export LC_ALL
In the csh or tsch shell:
setenv LC_ALL american.iso88591
Sybase IQ loads the localization information when it executes the INSERT...LOCATION statement.