Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Install MySQL with support for UTF-8 Unicode 1

Status
Not open for further replies.

likelylad

IS-IT--Management
Jul 4, 2002
388
GB
How do I install MySQL on a Windows PC so that it will support characters that conform to UTF-8 Unicode

Thanking in advance for any help received
 
If you wanted to use UTF-8 as the default character set, you would specify the option default-character-set=utf8 in the [mysqld] section of the my.ini or my.cnf file. You would need to do this before loading data into any tables. However, I don't see UTF-8 in the character sets directory in my MySQL 4.0.13 installation. You would probably need version 4.1, which is still in the alpha phase.

MySQL 4.1 also allows you to specify character sets for individual databases, tables, and fields, for example:[tt]
CREATE DATABASE db CHARACTER SET utf8;
CREATE TABLE t1
(
id INT,
name CHAR(10)
)
CHARACTER SET utf8;
CREATE TABLE t2
(
id INT,
name CHAR(10) CHARACTER SET utf8
);[/tt]

 
I had read from the MySQL site that 4.1 did support UTF8 but I didn't realise that I could set up individual tables.

Thanks for Your help
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top