background image
<< Setting Language and Territory Parameters | Setting the NLS_TERRITORY parameter >>
<< Setting Language and Territory Parameters | Setting the NLS_TERRITORY parameter >>

Using the NLS_TERRITORY Parameter

Establishing a Globalization Support Environment
6-10 Oracle Database 2 Day Developer's Guide
box, select
hr_conn
from the list of connections. The current language is listed
after
NLS_LANGUAGE
.
2.
Set the language to Italian.
ALTER SESSION SET NLS_LANGUAGE=ITALIAN;
3.
Enter a
SELECT
statement to check the format of the output after the change to
Italian.
SELECT last_name, hire_date, ROUND(salary/8,2) salary FROM employees
WHERE employee_id IN (111, 112, 113);
The output from the example should be similar to the following. Note that the
abbreviations for month names are in Italian.
LAST_NAME HIRE_DATE SALARY
------------------------- --------- ----------
Sciarra 30-SET-97 962.5
Urman 07-MAR-98 975
Popp 07-DIC-99 862.5
4.
Set the language to German.
ALTER SESSION SET NLS_LANGUAGE=GERMAN;
5.
Enter the same
SELECT
statement to check the format of the output after the
change to German.
SELECT last_name, hire_date, ROUND(salary/8,2) salary FROM employees
WHERE employee_id IN (111, 112, 113);
The output from the example should be similar to the following. Note that the
abbreviations for month names are now in German.
LAST_NAME HIRE_DATE SALARY
------------------------- --------- ----------
Sciarra 30-SEP-97 962.5
Urman 07-MRZ-98 975
Popp 07-DEZ-99 862.5
6.
Set
NLS_LANGUAGE
back to its original setting listed in Step 1. For example:
ALTER SESSION SET NLS_LANGUAGE=AMERICAN;
Using the NLS_TERRITORY Parameter
The
NLS_TERRITORY
parameter can be set to any valid territory name. The default is
derived from the
NLS_LANG
setting.
NLS_TERRITORY
specifies the conventions for
the following default date and numeric formatting characteristics:
Date format
Decimal character and group separator
Local currency symbol
See Also:
Oracle Database Reference for more information on the
NLS_
LANGUAGE
parameter
Oracle Database Globalization Support Guide for locale information,
including supported languages and territories