Are there any known problems caused by having NLS_LENGTH_SEMANTICS set to CHAR on an Oracle database?
-
29-09-2020 - |
Question
I've always thought that anyone using a database where NLS_LENGTH_SEMANTICS
set to BYTE
when using a multi-byte character set needed their heads examined, but recently a customer of ours said that they had experienced problems applying Oracle patches on databases where NLS_LENGTH_SEMANTICS
is set to CHAR
. Is there anything to this? Is it a known problem?
Solution
There's a useful page here that details any pros/cons/issues that you may encounter when setting the NLS_LENGTH_SEMANTICS
parameter.
To answer your question, make sure you set NLS_LENGTH_SEMANTICS=BYTE
when running any Oracle "internal" scripts. IE: patches, upgrades, anything in $ORACLE_HOME/dbms/admin
.
OTHER TIPS
According to the documentation:
Oracle strongly recommends that you do NOT set the NLS_LENGTH_SEMANTICS parameter to CHAR in the instance or server parameter file. This may cause many existing installation scripts to unexpectedly create columns with character length semantics, resulting in runtime errors, including buffer overflows.