简体   繁体   English

在MySQL中插入特殊字符

[英]inserting special character to mysql

INSERT INTO `tablecity` (`City`, `Country`) VALUES('胡志明市', 'Vietnam');

City become e883a1e5bf97e6988ee5b882 City成为e883a1e5bf97e6988ee5b882

What's wrong? 怎么了?

In some other databases this works fine. 在其他一些数据库中,这很好。 In the one I am working with I have this problem. 在与我一起工作的那个中,我有这个问题。

Does each table in mysql has their own encoding? mysql中的每个表都有自己的编码吗?

Does each table in mysql has their own encoding? mysql中的每个表都有自己的编码吗?

Yes. 是。 And each field as well. 而且每个领域也是如此。

We figured out the problem. 我们解决了问题。 The database, based on collation think that it's best to display e883a1e5bf97e6988ee5b882 if collation is binary. 基于排序规则的数据库认为,如果排序规则是二进制的,则最好显示e883a1e5bf97e6988ee5b882。

What's actually inside the database is correct. 数据库内部实际是正确的。

And yes we can change how it's displayed in phpmyadmin but there is no way to set that as default. 是的,我们可以更改它在phpmyadmin中的显示方式,但是无法将其设置为默认值。 The default is set by system administrator. 默认值由系统管理员设置。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM