Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.server -> Re: Full Ex/Im-port to New Instance, NT
Article-ID: <Note:48644.1> Revision: 0 PUBLIC Circulation: ** PUBLIC ** Creator: TOSCROFT.UK Folder: NLS Topic: * Using NLS Subject: Identifying the Export Character Set Modified: 19 Dec 97 01:18:15 Attachments: NONE
IDENTIFYING THE EXPORT CHARACTER SET
Introduction:
One of the most common NLS-related problems reported to Oracle Worldwide Customer Support is the loss or changing of characters after an export and import. This is almost always due to NLS_LANG being set to the incorrect character set during export.
Role of NLS_LANG During Export/Import:
This is explained in detail in <Note:15095.1> but, in brief, export and
import
are client tools and will work under the character set specified by
NLS_LANG.
If, for instance, the database is created with a character set of WE8DEC and
NLS_LANG is set to AMERICAN_AMERICA.WE8PC850 then the ascii values of the
stored
characters in the database will be translated to the values for the same
characters in the WE8PC850 character set. The character set defined by
NLS_LANG
during the export is stored in the export dump file and is used to ensure
that
the data is translated correctly to the character set defined by NLS_LANG
for
the import.
Potential Problems:
If NLS_LANG is not set, for instance, export will be done under US7ASCII,
the
default character set. If the database was built with character set WE8DEC
the characters stored in the database will be converted to US7ASCII and any
8-bit characters, having no equivalent in US7ASCII, will be stripped out.
The same problem will be seen if the character set defined by NLS_LANG is not a superset of the one being translated from (ie: the database character set on export or the export file character set on import).
Identifying the Export Character Set:
When investigating problems like these it is useful to check the character
set used for the export. As said above, this is held in the export dump
file.
It can be seen by doing a hex dump of the export file as follows (in Unix):
cat expdat.dmp | od -x > out.file
(if the export file is large you will still get the information you need if you Ctrl-C the command after a short while).
This will produce output similar to:
0000000 0300 0145 5850 4f52 543a 5630 372e 3033
0000020 2e30 330a 4454 534f 0a52 5441 424c 4553
0000040 0a31 3032 340a 300a 0020 2020 2020 2020
0000060 2020 2020 2020 2020 2020 2020 2020 2020
*
0000140 2020 2020 2020 2020 4d6f 6e20 4e6f 7620
0000160 3130 2031 343a 3031 3a33 3620 3139 3937
0000200 0a54 4142 4c45 2022 454d 5022 0a43 5245
0000220 4154 4520 5441 424c 4520 2245 4d50 2220
The third byte in the file defines the character set used for the export.
In this case, the second byte is 0x01. This shows that NLS_LANG was set to
US7ASCII during the export. The character set byte, when converted to
decimal,
corresponds to the character set id (See Note 13971.1).
The values for the most commonly used character sets are below:
US7ASCII 0x01 WE8DEC 0x02
TH8TISASCII 0x29 WE8ROMAN8 0x05 WE8PC850 0x0a US8PC437 0x04 EE8PC852 0x96 JA16EUC 0x3e JA16SJIS 0x40 ZHT16BIG5 0x40
begin 666 Yassir Khogaly.vcf
M0D5'24XZ5D-!4D0-"E9%4E-)3TXZ,BXQ#0I..DMH;V=A;'D[66%S<VER#0I&
M3CI987-S:7(@2VAO9V%L>0T*3U)'.D%%154-"E1)5$Q%.E-E;FEO<B!/<F%C
M;&4_at_1$)!#0I414P[2$]-13M63TE#13HK-#0H,"DQ.#$@-#8P-# T,@T*5$5,
M.T-%3$P[5D])0T4Z*S0T-#$Q.3 V-S<V#0I!1%([2$]-13M%3D-/1$E.1SU1
M54]4140M4%))3E1!0DQ%.CL[1FQA=" Y/3!$/3!!,3D_at_4V]U=&AL86YD)W,@
M1W)O=F4],$0],$$[0FEC:VQE>3M+96YT.T)2,2 R1$$[16YG;&%N9 T*3$%"
M14P[2$]-13M%3D-/1$E.1SU154]4140M4%))3E1!0DQ%.D9L870@.3TP1#TP
M03$Y(%-O=71H;&%N9"=S($=R;W9E/3!$/3!!/3!$/3!!0FEC:VQE>2P_at_2V5N
M="!"4C$@,D1!/3!$/3!!16YG;&$]#0IN9 T*55),.FAT=' Z+R]W=W<N:VAO
M9V%L>2YF<F5E<V5R=F4N8V\N=6L-"E523#IH='1P.B\O=W=W+F%E974N;W)G
M+G5K#0I%34%)3#M04D5&.TE.5$523D54.GEA<W-I<D!K:&]G86QY+F9R965S
M97)V92YC;RYU:PT*4D56.C$Y.3_at_Q,#$R5# W-3<R.%H-"D5.1#I60T%21 T*
`
end
Received on Mon Oct 12 1998 - 02:57:29 CDT