MySQL将表从Latin1转换为utf8 [英] MySQL convert table from Latin1 to utf8

查看:102
本文介绍了MySQL将表从Latin1转换为utf8的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我需要将包含大量数据的表从Latin1转换为utf8,以便它可以接受韩文字符.如何更改该表而不损坏其中的数据?我的SQL语句是什么?最好的进行方法是什么?

I need to convert a table with a lot of data from Latin1 to utf8 so that it can accept Korean characters. How do I alter that table without corrupting the data that's in there? What would my SQL statement be? What's the best way to proceed?

推荐答案

导出(转储)数据库,并使用新的编码将其重新导入.

Export (dump) the database, and reimport it with the new encoding.

http://alexking.org/blog/2008/03/06/mysql-latin1-utf8-conversion

这篇关于MySQL将表从Latin1转换为utf8的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆