Not the answer you need?
Register and ask your own question!
Many Forum changes were implemented on Tue 22 Sep. Read about new Ranks, Scoring, and Reactions.
Email [email protected] for any comments or concerns.

MySQL 5.x characterset change

geelwortelgeelwortel ContributorInactive User Role Beginner
Hi all
How do I change the charactset on mysql 5.x from utf8 to latin1.
Thanx for the help
Andrew

Comments

  • PeterPeter Percona CEO Percona Moderator Role
    I thought MySQL 5.0 still has latin1 as default unless you specify
    character-set=utf8 in my.cnf

    In any case to go to latin1 you probably need to change back server default and then convert all your tables back to latin1, this is done using something like

    ALTER TABLE ttt CONVERT TO CHARACTER SET latin1;

    I might not remember exact syntax corectly but it is not plain ALTER TABLE CHATSET latin1 as this would only adjust default character set for columns in the table.

    Just a warning - converting from utf8 to latin1 will cause data corruption if you have any non-latin1 stored in the database already.
Sign In or Register to comment.

MySQL, InnoDB, MariaDB and MongoDB are trademarks of their respective owners.
Copyright ©2005 - 2020 Percona LLC. All rights reserved.