Oracle 参数 NLS_TERRITORY 官方解释,作用,如何配置最优化建议
本站中文解释
NLS_TERRITORY参数是指定Oracle安装所在的国家或地区,用于控制语言环境。正确设置NLS_TERRITORY参数,首先需要确定Oracle安装所在的国家或地区,然后查找Oracle数据库安装目录中的数据库语言文件,根据Oracle文档中的要求,选择合适的地区名称(由Oracle数据字典里的NLS_TERRITORY这一参数的值提供)填入NLS_TERRITORY参数。
在Oracle数据字典中,查询NLS_TERRITORY这一参数的值,语句为:
SELECT PARAMETER, VALUE FROM NLS_DATABASE_PARAMETERS
WHERE PARAMETER LIKE ‘NLS_TERRITORY’;
根据查询的结果,配置NLS_TERRITORY参数。完成配置以后,重启数据库,使配置生效。
官方英文解释
NLS_TERRITORY
specifies the name of the territory whose conventions are to be followed for day and week numbering.
Property | Description |
---|---|
Parameter type |
String |
Syntax |
|
Default value |
Operating system-dependent |
Modifiable |
|
Modifiable in a PDB |
Yes |
Range of values |
Any valid territory name |
Basic |
Yes |
This parameter also establishes the default date format, the default decimal character and group separator, and the default ISO and local currency symbols.
For information on these settings, see “NLS_DATE_FORMAT”, “NLS_NUMERIC_CHARACTERS”, “NLS_CURRENCY”, and “NLS_ISO_CURRENCY”.
Note:
The value of this initialization parameter NLS_TERRITORY
is used to initialize the session value of this parameter, which is the actual value referenced by the SQL query processing. This initial value is overridden by a client-side value if the client uses the Oracle JDBC driver or if the client is OCI-based and the NLS_LANG
client setting (environment variable) is defined. The initialization parameter value is, therefore, usually ignored.
Examples
For an example of overriding the default value for the NLS_TERRITORY
parameter, see Oracle Database
Globalization Support Guide.
See Also:
-
Oracle Database
Globalization Support Guide for a complete list of territories -
Your operating system-specific Oracle documentation for the territory-dependent default values for these parameters