Go from Oracle 10g to Oracle 11g change character Set ____oracle

Source: Internet
Author: User

Work required, installing Oracle 11g, an error occurred while importing backup data on another machine:

IMP-00019: Line denied due to ORACLE error 12899
IMP-00003: ORACLE Error 12899 encountered
ORA-12899: Column "ZHENG". D_dic "." Dicexplain value is too large (actual: 140, Maximum: 100)

The structure of the datasheet is injected directly, and it doesn't. Later on the internet to find out the original is the problem of character set:

In the log file, when you start the import there is a hint: "

Import in the ZHS16GBK character set and Al16utf16 NCHAR character set has been completed
Import server uses Al32utf8 character set (possible character set conversion)


"Originally installed on my Windows Server 2003 system Oracle, the default character set is consistent with the operating system, is Al32utf8."

Al32utf8, a Chinese character is occupied by 3 characters, and generally we use the default in Windows XP is ZHS16GBK, a Chinese character with 2 characters bit. This allows direct import of data to overflow directly.

to view the character set of a database

SELECT * from V$nls_parameters;

SELECT * from Nls_database_parameters;

Character set changes for Oracle databases

[root@server183/]# Sqlplus/nolog

Sql*plus:release 11.2.0.1.0 Production on Wed Nov 7 23:50:56 2012

Copyright (c) 1982, Oracle. All rights reserved.

Sql> Conn/as SYSDBA--Need to use SYSDBA account

Connected.

Sql> Startup Mount

Ora-01081:cannot start already-running Oracle-shut it down

sql> shutdown immediate; --Stop the database

Database closed.

Database dismounted.

ORACLE instance shut down.

Sql> startup Mount-start database to Mount state

ORACLE instance started.

Total System Global area 1686925312 bytes

Fixed Size 2176368 bytes

Variable Size 989858448 bytes

Database buffers 687865856 bytes

Redo buffers 7024640 bytes

Database mounted.

Sql> alter session set Sql_trace=true;

Session altered.

Sql> alter system enable restricted session;

System altered.

Sql> alter system set job_queue_processes=0;

System altered.

Sql> alter system set aq_tm_processes=0;

System altered.

sql> ALTER DATABASE open;

Database altered.

Sql> ALTER DATABASE Character set Internal_use ZHS16GBK; --Modify Character Set AL32UTF8->ZHS16GBK

Database altered.

sql> shutdown immediate; --Close the database again

Database closed.

Database dismounted.

ORACLE instance shut down.

Sql> Startup--Start the database

ORACLE instance started.

Total System Global area 1686925312 bytes

Fixed Size 2176368 bytes

Variable Size 989858448 bytes

Database buffers 687865856 bytes

Redo buffers 7024640 bytes

Database mounted.

Database opened.

Sql> SELECT * from v$nls_parameters where parameter = ' nls_characterset ';

+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Client-side Character Set modification
In the. Bash_profile under the/home/oracle and/root user directory.
Add or modify Export nls_lang= "American_america." UTF8 "statement
Closes the current SSH window.

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.