database character sets utf8 
Author Message
 database character sets utf8

I have a question about database character sets.  

I need to change an Oracle 8.1.7 database character set from US7ASCII
to UTF8.   The db runs on Solaris 2.8.

My question is: "How to I find out from the database/data dictionary
and dynamic views what the database's character set is?"

My info source for this topic is the Oracle Generic Doumentation CD
for 8.1.7 , in particular:
Oracle8i National Language Support Guide
         Release 2 (8.1.6)

This sentence seemed to answer my question as to where to query to get
the database's character set:

"NLS_DATABASE_PARAMETERS shows the current NLS parameters of the
database, including the database character set."

So I do this query:
SQL> select * from nls_database_parameters
Where parameter = 'NLS_CHARACTERSET';
PARAMETER                      VALUE
------------------------------
----------------------------------------
NLS_CHARACTERSET               US7ASCII

From this I infer that the database's character set is US7ASCII.
The info in Oracle Documentation below makes me believe that I can
change the database character set from US7ASCII to UTF8:
"For instance, the following migration scenarios can take advantage of
the ALTER DATABASE CHARACTER SET statement because US7ASCII is a
strict subset of WE8ISO8859P1, ZHS16GBK, and UTF8:

Table 3-8 Sample Migration Scenarios
Current Character Set|New Character Set|New Character Set
                                        is Strict Superset?
 US7ASCII            WE8ISO8859P1             Yes
 US7ASCII            ZHS16GBK                Yes
 US7ASCII            UTF8                    Yes

So I try the commands to change the character set from US7ASCII to
UTF8, but they fail with this error:
SVRMGR> ALTER DATABASE CHARACTER SET UTF8;
ALTER DATABASE CHARACTER SET UTF8
                                 *
ORA-12712: new character set must be a superset of old character set

This leads me to believe that either my database's character set is
not US7ASCII, or the conversion is not possible as described by the
Oracle documentation.

I find the  create script for the database and find that the database
was created with explicit instructions to set the character set as
WE8ISO8859P1.

I think that the database's character set is WE8ISO8859P1, but I am
troubled that the data dictionary views/ dynamic views do not confirm
this.  Any help, explanations, experiences would be appreciated.
Thanks in advance.



Tue, 03 Feb 2004 05:27:45 GMT
 database character sets utf8

I've run into a similar problem. I tried the following and had a
successful conversion:

Login as system/<password>
SQL> SHUTDOWN IMMEDIATE;   -- or NORMAL
    <do a full backup>

SQL> STARTUP MOUNT;
SQL> ALTER SYSTEM ENABLE RESTRICTED SESSION;
SQL> ALTER SYSTEM SET JOB_QUEUE_PROCESSES=0;
SQL> ALTER DATABASE OPEN;
SQL> ALTER DATABASE CHARACTER SET <new_character_set_name>;
SQL> SHUTDOWN IMMEDIATE;   -- or NORMAL
SQL> STARTUP;

Quote:

> I have a question about database character sets.  

> I need to change an Oracle 8.1.7 database character set from US7ASCII
> to UTF8.   The db runs on Solaris 2.8.

> My question is: "How to I find out from the database/data dictionary
> and dynamic views what the database's character set is?"

> My info source for this topic is the Oracle Generic Doumentation CD
> for 8.1.7 , in particular:
> Oracle8i National Language Support Guide
>          Release 2 (8.1.6)

> This sentence seemed to answer my question as to where to query to get
> the database's character set:

> "NLS_DATABASE_PARAMETERS shows the current NLS parameters of the
> database, including the database character set."

> So I do this query:
> SQL> select * from nls_database_parameters
> Where parameter = 'NLS_CHARACTERSET';
> PARAMETER                      VALUE
> ------------------------------
> ----------------------------------------
> NLS_CHARACTERSET               US7ASCII

> From this I infer that the database's character set is US7ASCII.
> The info in Oracle Documentation below makes me believe that I can
> change the database character set from US7ASCII to UTF8:
> "For instance, the following migration scenarios can take advantage of
> the ALTER DATABASE CHARACTER SET statement because US7ASCII is a
> strict subset of WE8ISO8859P1, ZHS16GBK, and UTF8:

> Table 3-8 Sample Migration Scenarios
> Current Character Set|New Character Set|New Character Set
>                                         is Strict Superset?
>  US7ASCII            WE8ISO8859P1             Yes
>  US7ASCII            ZHS16GBK                Yes
>  US7ASCII            UTF8                    Yes

> So I try the commands to change the character set from US7ASCII to
> UTF8, but they fail with this error:
> SVRMGR> ALTER DATABASE CHARACTER SET UTF8;
> ALTER DATABASE CHARACTER SET UTF8
>                                  *
> ORA-12712: new character set must be a superset of old character set

> This leads me to believe that either my database's character set is
> not US7ASCII, or the conversion is not possible as described by the
> Oracle documentation.

> I find the  create script for the database and find that the database
> was created with explicit instructions to set the character set as
> WE8ISO8859P1.

> I think that the database's character set is WE8ISO8859P1, but I am
> troubled that the data dictionary views/ dynamic views do not confirm
> this.  Any help, explanations, experiences would be appreciated.
> Thanks in advance.



Sat, 07 Feb 2004 02:34:52 GMT
 database character sets utf8
Also, to check the changes took effect, query the v$nls_parameters view.

HTH,
Pete's

Quote:

> I've run into a similar problem. I tried the following and had a
> successful conversion:

> Login as system/<password>
> SQL> SHUTDOWN IMMEDIATE;   -- or NORMAL
>     <do a full backup>

> SQL> STARTUP MOUNT;
> SQL> ALTER SYSTEM ENABLE RESTRICTED SESSION;
> SQL> ALTER SYSTEM SET JOB_QUEUE_PROCESSES=0;
> SQL> ALTER DATABASE OPEN;
> SQL> ALTER DATABASE CHARACTER SET <new_character_set_name>;
> SQL> SHUTDOWN IMMEDIATE;   -- or NORMAL
> SQL> STARTUP;


> > I have a question about database character sets.  

> > I need to change an Oracle 8.1.7 database character set from US7ASCII
> > to UTF8.   The db runs on Solaris 2.8.

> > My question is: "How to I find out from the database/data dictionary
> > and dynamic views what the database's character set is?"

> > My info source for this topic is the Oracle Generic Doumentation CD
> > for 8.1.7 , in particular:
> > Oracle8i National Language Support Guide
> >          Release 2 (8.1.6)

> > This sentence seemed to answer my question as to where to query to get
> > the database's character set:

> > "NLS_DATABASE_PARAMETERS shows the current NLS parameters of the
> > database, including the database character set."

> > So I do this query:
> > SQL> select * from nls_database_parameters
> > Where parameter = 'NLS_CHARACTERSET';
> > PARAMETER                      VALUE
> > ------------------------------
> > ----------------------------------------
> > NLS_CHARACTERSET               US7ASCII

> > From this I infer that the database's character set is US7ASCII.
> > The info in Oracle Documentation below makes me believe that I can
> > change the database character set from US7ASCII to UTF8:
> > "For instance, the following migration scenarios can take advantage of
> > the ALTER DATABASE CHARACTER SET statement because US7ASCII is a
> > strict subset of WE8ISO8859P1, ZHS16GBK, and UTF8:

> > Table 3-8 Sample Migration Scenarios
> > Current Character Set|New Character Set|New Character Set
> >                                         is Strict Superset?
> >  US7ASCII            WE8ISO8859P1             Yes
> >  US7ASCII            ZHS16GBK                Yes
> >  US7ASCII            UTF8                    Yes

> > So I try the commands to change the character set from US7ASCII to
> > UTF8, but they fail with this error:
> > SVRMGR> ALTER DATABASE CHARACTER SET UTF8;
> > ALTER DATABASE CHARACTER SET UTF8
> >                                  *
> > ORA-12712: new character set must be a superset of old character set

> > This leads me to believe that either my database's character set is
> > not US7ASCII, or the conversion is not possible as described by the
> > Oracle documentation.

> > I find the  create script for the database and find that the database
> > was created with explicit instructions to set the character set as
> > WE8ISO8859P1.

> > I think that the database's character set is WE8ISO8859P1, but I am
> > troubled that the data dictionary views/ dynamic views do not confirm
> > this.  Any help, explanations, experiences would be appreciated.
> > Thanks in advance.



Sat, 07 Feb 2004 20:35:56 GMT
 
 [ 3 post ] 

 Relevant Pages 

1. Characters beyond ASCII in database ( US7ASCII and UTF8 character set )

2. Character set conversion to UTF8 from WE8ISO8859P1 to UTF8

3. character set conversion: AL24UTFFSS to UTF8

4. Export & Import with UTF8 Character Set

5. Non supported character set: oracle-character-set-96

6. db character set & N character set

7. utf8 ,sqlplus, unix, sqlldr and character translation

8. UTF8 characters in an ASCII7 Oracle Instance.

9. migrating data from en_us.819 to en_us.utf8, Chinese characters and Unicode PERL modules

10. Solution: UCS2 / UTF8 / Oracle / Fail to convert between UTF8 and UCS2

11. Moving 6.5 database to another 6.5 database with different character set

12. One database server with different character set and sort order for different database


 
Powered by phpBB® Forum Software