ORA-12701: CREATE DATABASE character set is not known


When I set the character set I made a mistake.Then when start the database again there is an error message like the title.

I can't open the database so have no idea of redefine the character set.

where can I find the character set parameter that used when the database is created and how to modify it?

Thanks very much.

Vivian Qi
Who is Participating?
JankovskyConnect With a Mentor Commented:
There is only possibility, if you don't want recreate database (I think, it's better). There is an information about character set in file, but it's binary ORACLE CONTROL FILE. You can change it, using CREATE CONTROLFILE ... statement, but it's painful.
1. connect to ORACLE as sysdba
   sqlplus /nolog
   SQL> connect / as sysdba
2. SQL> startup nomount
3. SQL> alter database mount;
4. now database is mounted, but it isn't opened.
   you can select V$ views:
    select * from v$logfile;
    select * from v$datafile;
5. create statement for CREATE CONTROLFILE with
   specification of correct characterset
6. open the database.

Yes, :look in bdump rep file : alert_SID.log .
You can find " create datbase" and "character set" .
vivianQQAuthor Commented:
But if i modify the character set in this file the database can get the correct characterset parameter and be opened connectly?
This looks just like an log file which record the message about the changes that made on the database.It's not the confige file that will be read when the database is created.

I have checked the initSID.ora but can't find the parameter that references to the character set.

Thank U anyway
Never miss a deadline with monday.com

The revolutionary project management tool is here!   Plan visually with a single glance and make sure your projects get done.

Guy Hengel [angelIII / a3]Billing EngineerCommented:
You must recreate the database, there is no wait to redefine/change it after the database is created...
If you whant to find the character set :
-It is in the alert_SID.log file (location given in BDUMP variable in your pfile). Do you know where is your alert_SID.log file ?
-If your  database is 8.  and your character set not standard you have to set the ennv variblae ORA_NLS33.
exemple for Unix:
ORA_NLS33=$ORACLE_HOME/ocommon/nls/admin/data ; export ORA_NLS
vivianQQAuthor Commented:
Maybe I should describe the question more clearly.

I want to change the characterset to ZHS16GBK which is the standard characterset of oracle but I typed it as ZHS16CGBK so the oracle gave out the error:ORA-12701: CREATE DATABASE character set is not known.

I use the oracle for linux so I think there must be a file which contain the initial confige information of the DATABASE. Is it right?

I have took a look on the alter_SID.log.There R many log informations just like I supposed.
you could see the correct character set parameters in the documentation...
And I think Angelll is wrong, to change the character set you could do it, closing your database, enabling the restricted session, then a user with restricted session role can change the character set but only if the database is in exclusive mode with alter database character set WE8ISO....


If you don't have any data in your database, the easiest thing to do is to recreate the database again.

If you have data in it (which i guess not since you are not able to open it again), you have to do an export and import.

ALTER DATABASE CHARACTER SET statement cannot be used when the new characterset is not a strict superset of old characterset.  This can be used only if you are changing it from US7ASCII to WE8ISO8859P1 or ZHS16GBK or UTF8.

- Ramesh
    Hay in the init<sid>.ora file if u didn't specify the character set at the time of database creation means it will take the default(so it won't e displayed) any way u can change that by specifing NLS_LANG = AMERICAN_AMERICA.UTF8(this u can see from u'r documentation) for the characteset which u had specified.

    Other way u can try is in the registry u can change the NLS_LANG value.I don't know Linux so u can see the place where the oracle oriented things will be stored in th e resgistry and change it.

Note: Important thing is the new characterset want to be a superset of the existing one.

Hope this will give u some idea.If u are having any further qurey means post the question.

All Courses

From novice to tech pro — start learning today.