import server uses ZHS16GBK character set (possible charset conversion)

来源:互联网 发布:怎么取消淘宝网店 编辑:程序博客网 时间:2024/05/20 06:06

源库:
[oracle@redhat31 ~]$  env |grep LANG
LANG=en_US.UTF-8
[oracle@redhat31 ~]$
SQL> select * from database_properties;

PROPERTY_NAME                  PROPERTY_VALUE
------------------------------ ----------------------------------------------------------------------------------------------------------------------------
DICT.BASE                      2
DEFAULT_TEMP_TABLESPACE        TEMP
DEFAULT_PERMANENT_TABLESPACE   USERS
DEFAULT_TBS_TYPE               SMALLFILE
NLS_LANGUAGE                   AMERICAN
NLS_TERRITORY                  AMERICA
NLS_CURRENCY                   $
NLS_ISO_CURRENCY               AMERICA
NLS_NUMERIC_CHARACTERS         .,
NLS_CHARACTERSET               ZHS16GBK
NLS_CALENDAR                   GREGORIAN

PROPERTY_NAME                  PROPERTY_VALUE
------------------------------ ----------------------------------------------------------------------------------------------------------------------------
NLS_DATE_FORMAT                DD-MON-RR
NLS_DATE_LANGUAGE              AMERICAN
NLS_SORT                       BINARY
NLS_TIME_FORMAT                HH.MI.SSXFF AM
NLS_TIMESTAMP_FORMAT           DD-MON-RR HH.MI.SSXFF AM
NLS_TIME_TZ_FORMAT             HH.MI.SSXFF AM TZR
NLS_TIMESTAMP_TZ_FORMAT        DD-MON-RR HH.MI.SSXFF AM TZR
NLS_DUAL_CURRENCY              $
NLS_COMP                       BINARY
NLS_LENGTH_SEMANTICS           BYTE
NLS_NCHAR_CONV_EXCP            FALSE

PROPERTY_NAME                  PROPERTY_VALUE
------------------------------ ----------------------------------------------------------------------------------------------------------------------------
NLS_NCHAR_CHARACTERSET         AL16UTF16
NLS_RDBMS_VERSION              10.2.0.1.0
GLOBAL_DB_NAME                 PROD.REGRESS.RDBMS.DEV.US.ORACLE.COM
EXPORT_VIEWS_VERSION           8
DBTIMEZONE                     00:00

27 rows selected.

SQL>
SQL> exit

 

 

目标库:
[oracle@redhat32 ~]$  env |grep LANG
LANG=en_US.UTF-8
[oracle@redhat32 ~]$

SQL> select * from database_properties;
rows will be truncated


PROPERTY_NAME                  PROPERTY_VALUE
------------------------------ -------------------------------------------------------------------------------------------------------------------------------------------------------------------------
DICT.BASE                      2
DEFAULT_TEMP_TABLESPACE        TEMP
DEFAULT_PERMANENT_TABLESPACE   USERS
DEFAULT_TBS_TYPE               SMALLFILE
NLS_LANGUAGE                   AMERICAN
NLS_TERRITORY                  AMERICA
NLS_CURRENCY                   $
NLS_ISO_CURRENCY               AMERICA
NLS_NUMERIC_CHARACTERS         .,
NLS_CHARACTERSET               ZHS16GBK
NLS_CALENDAR                   GREGORIAN

PROPERTY_NAME                  PROPERTY_VALUE
------------------------------ -------------------------------------------------------------------------------------------------------------------------------------------------------------------------
NLS_DATE_FORMAT                DD-MON-RR
NLS_DATE_LANGUAGE              AMERICAN
NLS_SORT                       BINARY
NLS_TIME_FORMAT                HH.MI.SSXFF AM
NLS_TIMESTAMP_FORMAT           DD-MON-RR HH.MI.SSXFF AM
NLS_TIME_TZ_FORMAT             HH.MI.SSXFF AM TZR
NLS_TIMESTAMP_TZ_FORMAT        DD-MON-RR HH.MI.SSXFF AM TZR
NLS_DUAL_CURRENCY              $
NLS_COMP                       BINARY
NLS_LENGTH_SEMANTICS           BYTE
NLS_NCHAR_CONV_EXCP            FALSE

PROPERTY_NAME                  PROPERTY_VALUE
------------------------------ -------------------------------------------------------------------------------------------------------------------------------------------------------------------------
NLS_NCHAR_CHARACTERSET         AL16UTF16
NLS_RDBMS_VERSION              10.2.0.1.0
GLOBAL_DB_NAME                 PROD.REGRESS.RDBMS.DEV.US.ORACLE.COM
EXPORT_VIEWS_VERSION           8
DBTIMEZONE                     00:00

27 rows selected.


未设置 NLS_LANG 时的导出:

[oracle@redhat31 ~]$ exp file=new4.dmp TABLESPACES=new TRANSPORT_TABLESPACE=y

Export: Release 10.2.0.1.0 - Production on Wed Aug 22 12:38:47 2012

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


Username: system/oracle as sysdba

Connected to: Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - Production
With the Partitioning, OLAP and Data Mining options
Export done in US7ASCII character set and AL16UTF16 NCHAR character set
server uses ZHS16GBK character set (possible charset conversion)
Note: table data (rows) will not be exported
About to export transportable tablespace metadata...
For tablespace NEW ...
. exporting cluster definitions
. exporting table definitions
. . exporting table                            NEW
. exporting referential integrity constraints
. exporting triggers
. end transportable tablespace metadata export
Export terminated successfully without warnings.
[oracle@redhat31 ~]$


未设置 NLS_LANG 时的导入:
[oracle@redhat32 ~]$ imp file=new4.dmp TRANSPORT_TABLESPACE=y TABLESPACES=new datafiles='/u01/app/oracle/oradata/omss/new01.dbf'

Import: Release 10.2.0.1.0 - Production on Wed Aug 22 09:37:51 2012

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

Username: sys/oracle as sysdba

Connected to: Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - Production
With the Partitioning, OLAP and Data Mining options

Export file created by EXPORT:V10.02.01 via conventional path
About to import transportable tablespace(s) metadata...
import done in US7ASCII character set and AL16UTF16 NCHAR character set
import server uses ZHS16GBK character set (possible charset conversion)
. importing SYS's objects into SYS
. importing SYS's objects into SYS
IMP-00017: following statement failed with ORACLE error 604:
 "BEGIN   sys.dbms_plugts.commitPluggable; END;"
IMP-00003: ORACLE error 604 encountered
ORA-00604: error occurred at recursive SQL level 1
ORA-16000: database open for read-only access
ORA-06512: at "SYS.DBMS_PLUGTS", line 2119
ORA-06512: at line 1
IMP-00000: Import terminated unsuccessfully
[oracle@redhat32 ~]$

 

 


设置 NLS_LANG 时的导出:
[oracle@redhat31 ~]$ export NLS_LANG=AMERICAN_AMERICA.ZHS16GBK
[oracle@redhat31 ~]$
[oracle@redhat31 ~]$ env |grep LANG
NLS_LANG=AMERICAN_AMERICA.ZHS16GBK
LANG=en_US.UTF-8
[oracle@redhat31 ~]$
[oracle@redhat31 ~]$ exp file=new5.dmp TABLESPACES=new TRANSPORT_TABLESPACE=y

Export: Release 10.2.0.1.0 - Production on Wed Aug 22 12:53:26 2012

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


Username: system/oracle as sysdba

Connected to: Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - Production
With the Partitioning, OLAP and Data Mining options
Export done in ZHS16GBK character set and AL16UTF16 NCHAR character set
Note: table data (rows) will not be exported
About to export transportable tablespace metadata...
For tablespace NEW ...
. exporting cluster definitions
. exporting table definitions
. . exporting table                            NEW
. exporting referential integrity constraints
. exporting triggers
. end transportable tablespace metadata export
Export terminated successfully without warnings.
[oracle@redhat31 ~]$

 

设置 NLS_LANG 时的导入:

[oracle@redhat32 ~]$ export NLS_LANG=AMERICAN_AMERICA.ZHS16GBK
[oracle@redhat32 ~]$  env |grep LANG
NLS_LANG=AMERICAN_AMERICA.ZHS16GBK
LANG=en_US.UTF-8
[oracle@redhat32 ~]$
[oracle@redhat32 ~]$ scp 192.168.11.31:/home/oracle/new5.dmp .               
password:
new5.dmp                                                                                  100%   16KB  16.0KB/s   00:00   
[oracle@redhat32 ~]$
[oracle@redhat32 ~]$ export ORACLE_SID=omss
[oracle@redhat32 ~]$ imp file=new5.dmp TRANSPORT_TABLESPACE=y TABLESPACES=new datafiles='/u01/app/oracle/oradata/omss/new01.dbf'

Import: Release 10.2.0.1.0 - Production on Wed Aug 22 10:15:43 2012

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

Username: sys/oracle as sysdba

Connected to: Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - Production
With the Partitioning, OLAP and Data Mining options

Export file created by EXPORT:V10.02.01 via conventional path
About to import transportable tablespace(s) metadata...
import done in ZHS16GBK character set and AL16UTF16 NCHAR character set
. importing SYS's objects into SYS
. importing SYS's objects into SYS
. importing SCOTT's objects into SCOTT
. . importing table                          "NEW"
. importing SYS's objects into SYS
Import terminated successfully without warnings.
[oracle@redhat32 ~]$




更多参考:


the specified nodes are not clusterable

根据rowid删除表中重复的行

Agent process exited abnormally during initialization

一次字符乱码的解决过程

rman实验(一)

rman实验(二)

ORA-00600: internal error code, arguments: [keltnf

ORA-00600: ORA-12012 ORA-08102解决

linux下完全删除oracle

INFO: /usr/bin/ld: crt1.o: No such file: No such file or directory

centos4.8_64上安装oracle10201建库报ORA-12547

EM乱码解决

ORA-31613 Master process DM00 failed during startup

ORA-00600: internal error code, arguments: [4194], [29], [27], [], [], [], [], []

ORA-24324 ORA-01041 ORA-03113

centos5.3升级oracle

pdksh-5.2.14-36.el5.i386.rpm

使用rman进行数据库迁移

oracle10.2.0.1升级到10.2.0.4报错

Upgrade Oracle 10g from 10.2.0.1 to 10.2.0.4 (Single Instance)

改oracle的name和dbid

修改oracle实例名

Solaris8上迁移oracle8i---上

Solaris8上迁移oracle8i---下

未备份归档日志导致数据丢失的实验

使用NBU进行数据库迁移

catalog备份数据库

RMAN FORMAT字符串格式化

Error: can not register my instance state - -1

not all alterations performed

The ASM instance configured on the local node is a single-instance ASM

/u01/crs102/bin/crsctl.bin: error while loading shared libraries: libstdc++.so.5: cannot open shared

Initializing the Oracle ASMLib driver: [FAILED]

ORA-00245: control file backup operation failed

WARNING: failed to read mirror side 1 of virtual extent 229 logical extent

模拟恢复参数文件

Interface eth0 checked failed

import server uses ZHS16GBK character set (possible charset conversion)