将多字节字符从 MSSQL 服务器迁移到 MySQL
我正在编写 PHP 脚本来将数据从 Microsoft SQL Server 迁移到 MySQL,到目前为止,除了多字节字符外,一切都很顺利。有人可以帮我解决这个问题吗?从PHP和MySQL数据库的角度来看,有哪些需要注意的地方?
- 我需要对 MySQL 配置进行一些更改吗?
- 我是否必须更改 PHP 中的多字节字符的字符编码,如果是,如何更改?
- 我还缺少什么吗?
谢谢。
I am writing PHP scripts to migrate data from Microsoft SQL Server to MySQL, this has been smooth so far, except multibyte characters. can somebody help me to get over with this. What are the points that should be taken care of from PHP and MySQL database perspective.
- Do i have to make some changes in MySQL configuration?
- Do i have to change character encoding in PHP for multibyte characters, if yes how?
- Is there anything else i am missing?
Thanks.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
我最近为我们公司的网站添加了一个翻译模块。我执行了以下操作以确保数据库能够实现多字节良好
SET NAMES utf8
来完成此操作。 但是,还有其他方法可以做到这一点(我添加了SET NAMES utf8
,因为我就是这样做的。)以下线程有更多信息
在 MySQL 中设置名称 utf8?
是否使用“SET NAMES”
I recently added a translation module for our company's website. I did the following to make sure the DB was up for multibyte goodness
SET NAMES utf8
prior to transferring. However, there are other ways to do this (I addedSET NAMES utf8
because that's how I did it.)The following threads have more info
SET NAMES utf8 in MySQL?
Whether to use "SET NAMES"