葡萄牙语的MySQL归类 [英] MySQL collation for Portugese

查看:143
本文介绍了葡萄牙语的MySQL归类的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在MySQL中,是否有一种方法可以按照葡萄牙语语言对字符进行整理?用同样的方式,有utf8_spanish_ci或西班牙文。还是可以添加新的排序规则?

Is there a way in MySQL to have character collated as per the Portugese language? In the same way there is utf8_spanish_ci or Spanish. Or is there a way to add new collations?

有以下字符:

ç (Gonçalves)
ã (Guimarães)
õ (Simões)
â (Tânger)
ô (Pôrto)
ê (Gouvêa)
é (Féria)
í (Vinícius)
ó (Grijó)
ú (Araújo)
á (Tomás)
ñ (Núñez)

使用utf8_general_ci搜索Gonçalves时,也会返回 Goncalves。我需要将它们分别由MySQL对待。

When using utf8_general_ci searching for 'Gonçalves' would also return 'Goncalves'. I need these to be treated separately by MySQL.

推荐答案

根据 http://mysql.rjweb.org/utf8mb4_collat​​ions.html 并在MySQL中进行了测试,latin1_general_ci是可正确区分OP所包含字符的排序规则确定的

According to http://mysql.rjweb.org/utf8mb4_collations.html, and tested in MySQL, the latin1_general_ci is the collation that correctly differentiates between the characters the OP has identified

它也可以对其进行正确排序,并且不会将Ç转换为C。

It also sorts it properly, and does not transform Ç into C for instance.

这篇关于葡萄牙语的MySQL归类的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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