MySQL Latin-1编码问题 [英] Mysql Latin-1 encoding problem

查看:72
本文介绍了MySQL Latin-1编码问题的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述



我需要将数据从使用php和mysql构建的旧网站迁移到由.Net和SQlServer构建的新网站.大多数数据库内容都使用阿拉伯语.
我面临的问题是,mysql数据库被编码为"latin-1",当我使用在线ecplorer或mysql工作台查看数据库时,它显示了奇怪的字符,但在旧的php中工作正常网站(好像php可以将其转换为正确的编码)..
但是当使用asp.net页面显示数据时,它仍然显示奇怪的字符. 我尝试将数据库导出到utf-8,但没有用(它仅转换要添加的行,而不转换已存在的行),我也尝试添加以下内容我的html的meta标签:
<"meta>

提前谢谢..&>

Hi,

I need to move data from a legacy website that''s built using php and mysql to a new website built by .Net and SQlServer.. Most of the database content are in Arabic.
The problem i''m facing is that the mysql db is encoded as ''latin-1'', when i view the db using online ecplorer or mysql workbench it shows weird chars, but it''s working fine in the old php website (seems like php has a way to convert it to proper encoding)..
But when showing data using asp.net pages it still shows weird chars..
I''ve tried to export the db to utf-8 but it didn''t work(it only converts the rows to be added, not the one''s that already exists), also I''ve tried adding the following meta tag to my html:
<"meta>

Thanks in advance..&>

推荐答案

看看那些链接:

http://www.leinadium.com/code/mysql-migration -toolkit-mssql-latin1-to-mysql-utf8/ [ http://stackoverflow.com/questions/4712877/migration-utf-8-data-from-mysql-to-sql-server-2005 [ http://blogs.msdn.com/b/ssma/archive/2011/04/29/converting-from-mysql-to-sql-server-working-with-data-types.aspx [ http://yoonkit.blogspot.com.es/2006/03/mysql-charset-from-latin1-to-utf8.html [ http://www.niden.net/2011/12/change-encoding-of-mysql-database-to.html#!/2011/12/change-encoding-of-mysql-database-to. html [
祝你好运!
Take a look at those links:

http://www.leinadium.com/code/mysql-migration-toolkit-mssql-latin1-to-mysql-utf8/[^]
http://stackoverflow.com/questions/4712877/migrate-utf-8-data-from-mysql-to-sql-server-2005[^]
http://blogs.msdn.com/b/ssma/archive/2011/04/29/converting-from-mysql-to-sql-server-working-with-data-types.aspx[^]
http://yoonkit.blogspot.com.es/2006/03/mysql-charset-from-latin1-to-utf8.html[^]
http://www.niden.net/2011/12/change-encoding-of-mysql-database-to.html#!/2011/12/change-encoding-of-mysql-database-to.html[^]

I hope any of those links will help you, just in case they won''t, I''ve searched Google by using this text: "from mysql to sql server changing encoding" (without the double quotes).

Good luck!


这篇关于MySQL Latin-1编码问题的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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