Home » RDBMS Server » Server Administration » Multibyte character set problem
Multibyte character set problem [message #121543] Mon, 30 May 2005 09:19 Go to next message
kumarsz
Messages: 180
Registered: March 2005
Location: canada
Senior Member
Hello,
we have a requirement to store Multibyte (chinese characters).
our existing database properties are given below( NLS_NCHAR_CHARACTERSET UTF8)
when i was checking with my application
i got surprsing conclusions!
i seek your guidence for the same.
earlier column subject was storing 40 english characters
so we create table
create table mail_params(subject varchar2(40))

when i checked it with various combination to staore 40 chinese charcaters i was successful only when i made floowing chnage in my database.
alter table mail_params modify subject nvarchar2(120)

but in TOAD i was seeing the column size after describing the table as
subject nvarchar2(360)

Can anybody suggest me what would the appropriate chnage to the original structure of "subject varchar2(40)" so as to store 40 chinese charcaters?

kindly note that NLS_CHARACTERSET is UTF8.

PROPERTY_NAME PROPERTY_VALUE DESCRIPTION

DBTIMEZONE +05:30 DB time zone
NLS_LANGUAGE AMERICAN Language
NLS_TERRITORY AMERICA Territory
NLS_NUMERIC_CHARACTERS Numeric characters
NLS_CHARACTERSET UTF8 Character set
NLS_CALENDAR GREGORIAN Calendar system
NLS_DATE_LANGUAGE AMERICAN Date language
NLS_TIME_FORMAT HH.MI.SSXFF AM Time format
NLS_TIMESTAMP_FORMAT DD-MON-RR HH.MI.SSXFF AM Time stamp format
NLS_TIME_TZ_FORMAT HH.MI.SSXFF AM TZR Time with timezone format
NLS_TIMESTAMP_TZ_FORMAT DD-MON-RR HH.MI.SSXFF AM TZR Timestamp with timezone format
NLS_LENGTH_SEMANTICS BYTE NLS length semantics
NLS_NCHAR_CONV_EXCP FALSE NLS conversion exception
NLS_NCHAR_CHARACTERSET UTF8 NCHAR Character set
NLS_RDBMS_VERSION 9.2.0.1.0 RDBMS version for NLS parameters

Thanks in Advance
Pratap
Re: Multibyte character set problem [message #121684 is a reply to message #121543] Tue, 31 May 2005 08:59 Go to previous message
smartin
Messages: 1803
Registered: March 2005
Location: Jacksonville, Florida
Senior Member
I have not yet had to work with multiple languages, so I'm not sure what help I can be. But, any time you declare a variable, such as varchar2(40), the 40 means either 40 bytes or 40 characters. If each character is one byte, then this is not an issue. But if characters can be multiple bytes, then it is a good idea to explicitly specify whether you mean varchar2(40 byte) or varchar2(40 char).
Previous Topic: Create new db schema? How?
Next Topic: Strange ORA-12514 Problem
Goto Forum:
  


Current Time: Fri Jan 10 07:16:21 CST 2025