在MySQL 5中我需要哪个dbExpress ServerCharSet用于utf8数据? [英] Which dbExpress ServerCharSet do I need for utf8 data in MySQL 5?
本文介绍了在MySQL 5中我需要哪个dbExpress ServerCharSet用于utf8数据?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
根据新闻组中的信息,我们尝试了 ServerCharSet = utf8
和 ServerCharSet = UTF8
-但仍然很特殊字符/ Umlauts不能正确显示在客户端数据中。
We tried ServerCharSet=utf8
and ServerCharSet=UTF8
, based on information found in newsgroups - but still, special characters / Umlauts do not appear correctly in the client data.
我们使用Delphi 2009和内置的dbExpress驱动程序。使用AsWideString检索字段数据。
We use Delphi 2009 and the built-in dbExpress driver. Field data is retrieved using AsWideString.
推荐答案
您必须设置 client 字符集。
简单的 SET NAMES utf8
查询在连接后立即执行,可以解决问题
you have to set up a client charset.
Simple "SET NAMES utf8
" query, executed right after connect, will do the trick
这篇关于在MySQL 5中我需要哪个dbExpress ServerCharSet用于utf8数据?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文