Unicode :
A Unicode character takes more bytes to store the data in the database. As we all know, many global industries want to increase their business worldwide and grow at the same time, they would want to widen their business by providing services to the customers worldwide by supporting different languages like Chinese, Japanese, Korean, and Arabic. Many websites these days are supporting international languages to do their business and to attract more and more customers and that makes life easier for both parties.
Non-Unicode
:
Non
Unicode is exactly the opposite of Unicode. Using non-Unicode it is easy to store
languages like ‘English’ but not other Asian languages that need more bits to
store correctly otherwise truncation will occur.
Now,
let’s see some of the advantages of not storing the data in the Unicode format:
1. It
takes less space to store the data in the database hence we will save a lot of
hard disk space.
2. Moving database files from one server to another takes less time.
2. Moving database files from one server to another takes less time.
What’s the difference
between a Unicode and non-Unicode Tools install?
SOLUTION:
If UNICODE_ENABLED=1 on the PSSTATUS table, then you definitely have a Unicode installation. If UNICODE_ENABLED=0, then you do NOT have a Unicode installation.
SOLUTION:
If UNICODE_ENABLED=1 on the PSSTATUS table, then you definitely have a Unicode installation. If UNICODE_ENABLED=0, then you do NOT have a Unicode installation.
Non-Unicode
|
Unicode
|
(char, varchar, text)
|
(nchar, nvarchar,
ntext)
|
Stores data in fixed
or variable length
|
Same as non-Unicode
|
char: data is padded with blanks to fill the field
size. For example, if a char(10) field contains 5 characters the system will
pad it with 5 blanks
|
nchar: same as char
|
varchar: stores actual value and does not pad with
blanks
|
nvarchar: same as varchar
|
requires 1
byte of storage
|
requires 2
bytes of storage
|
char and varchar: can store up
to 8000 characters
|
nchar and nvarchar: can store up
to 4000 characters
|
Best suited for the US
English: "One problem with data types that use 1 byte to encode each
character is that the data type can only represent 256 different characters.
This forces multiple encoding specifications (or code pages) for different alphabets such as European alphabets, which are relatively small. It is also
impossible to handle systems such as the Japanese Kanji or Korean Hangul
alphabets that have thousands of characters."1
|
Best suited for
systems that need to support at least one foreign language:
"The Unicode specification defines a single encoding scheme for most characters widely used in businesses around the world. All computers consistently translate the bit patterns in Unicode data into characters using the single Unicode specification. This ensures that the same bit pattern is always converted to the same character on all computers. Data can be freely transferred from one database or computer to another without concern that the receiving system will translate the bit patterns into characters incorrectly.
|
No comments:
Post a Comment