Skip to Main Content
  • Questions
  • How to select NLS_DATABASE_PARAMETERS for PDB$SEED and PDBs

Breadcrumb

Question and Answer

Sergiusz Wolicki

Thanks for the question.

Asked: July 12, 2022 - 11:49 pm UTC

Last updated: July 12, 2022 - 11:49 pm UTC

Version:

Viewed 1000+ times

You Asked

Hi,
In Oracle 19c, is it possible to create a PDB with NLS_TERRITORY = SPAIN in a CDB with NLS_TERRITORY = SPAIN?
We created a PDB in a CDB with NLS_TERRITORY = SPAIN, and pdb is AMERICAN.AMERICA.
We also had modified the values in pdbseed.xml before database creation but PDB$SEED is created with AMERICAN.AMERICA anyway, and new PDBS also had AMERICAN.AMERICA.

Thanks a lot.

and we said...

The way the Database Configuration Assistant (DBCA) creates multitenant databases seems to make it impossible to set NLS_DATABASE_PARAMETERS to values of your choice. This is a bug that needs to be filed. A workaround is to create a database from scratch using the process described in the Database Administrator's Guide: https://docs.oracle.com/en/database/oracle/oracle-database/21/multi/creating-and-configuring-an-oracle-database.html#GUID-18B03451-5C74-4B53-A892-656C3E8A2556

In step 4 of this process, the required NLS parameters should be added to the initialization file. They will be used by the CREATE DATABASE statement executed in step 9. CREATE DATABASE in multitenant mode will use the current NLS initialization parameters for both CDB$ROOT and PDB$SEED. PDBs created from the PDB$SEED will inherit the seed's parameter values.

Once CREATE DATABASE has finished, you can change the NLS initialization parameters if you want NLS_INSTANCE_PARAMETERS to be different from the NLS_DATABASE_PARAMETERS -- this is not usually needed though.

 


Is this answer out of date? If it is, please let us know via a Comment

More to Explore

Multitenant

Need more information on Multitenant? Check out the Multitenant docs for the Oracle Database