w

Hi,

You can check and compare sort orders provided by these two collations here:

http://www.collation-charts.org/mysql60/mysql604.utf8_general_ci.european.html 
http://www.collation-charts.org/mysql60/mysql604.utf8_unicode_ci.european.html

utf8_general_ci is a very simple collation. What it does - it just 
- removes all accents 
- then converts to upper case 
and uses the code of this sort of "base letter" result letter to compare.

For example, these Latin letters: ÀÁÅåāă (and all other Latin letters "a" 
with any accents and in any cases) are all compared as equal to "A".

utf8_unicode_ci uses the default Unicode collation element table (DUCET).

The main differences are:

1. utf8_unicode_ci supports so called expansions and ligatures, for example: 
German letter ß (U+00DF LETTER SHARP S) is sorted near "ss" 
Letter Œ (U+0152 LATIN CAPITAL LIGATURE OE) is sorted near "OE".

utf8_general_ci does not support expansions/ligatures, it sorts 
all these letters as single characters, and sometimes in a wrong order.

2. utf8_unicode_ci is *generally* more accurate for all scripts. 
For example, on Cyrillic block: 
utf8_unicode_ci is fine for all these languages: 
Russian, Bulgarian, Belarusian, Macedonian, Serbian, and Ukrainian. 
While utf8_general_ci is fine only for Russian and Bulgarian subset of Cyrillic. 
Extra letters used in Belarusian, Macedonian, Serbian, and Ukrainian 
are sorted not well.

The disadvantage of utf8_unicode_ci is that it is a little bit 
slower than utf8_general_ci.

So when you need better sorting order - use utf8_unicode_ci, 
and when you utterly interested in performance - use utf8_general_ci.

Character Sets, Collation, Unicode :: utf8_unicode_ci vs utf8_general_ci的更多相关文章

  1. 3个问题:MySQL 中 character set 与 collation 的理解;utf8_general_ci 与 utf8_unicode_ci 区别;uft8mb4 默认collation:utf8mb4_0900_ai_ci 的含义

    MySQL 中 character set 与 collation 的理解 出处:https://www.cnblogs.com/EasonJim/p/8128196.html 推荐: 编码使用 uf ...

  2. mysql补充(1)校对集utf8_unicode_ci与utf8_general_ci

    创建数据库并设置编码utf-8 多语言(补充1 2) create database mydb default character set utf8 collate utf8_general_ci; ...

  3. Firebird Character Sets and Collations

    Firebird Character Sets and Collations Every CHAR or VARCHAR field can (or, better: must) have a cha ...

  4. 【转】Mysql中的排序规则utf8_unicode_ci、utf8_general_ci的区别总结

    Mysql中utf8_general_ci与utf8_unicode_ci有什么区别呢?在编程语言中,通常用unicode对中文字符做处理,防止出现乱码,那么在MySQL里,为什么大家都使用utf8_ ...

  5. Mysql中的排序规则utf8_unicode_ci、utf8_general_ci的区别总结

    Mysql中utf8_general_ci与utf8_unicode_ci有什么区别呢?在编程语言中,通常用unicode对中文字符做处理,防止出现乱码,那么在MySQL里,为什么大家都使用utf8_ ...

  6. 10.1.5 Connection Character Sets and Collations

    10.1.5 Connection Character Sets and Collations Several character set and collation system variables ...

  7. utf8_unicode_ci与utf8_general_ci

    下面摘录一下Mysql 5.1中文手册中关于utf8_unicode_ci与utf8_general_ci的说明: 当前,utf8_unicode_ci校对规则仅部分支持Unicode校对规则算法.一 ...

  8. Mysql中的排序规则utf8_unicode_ci、utf8_general_ci总结

    Mysql中utf8_general_ci与utf8_unicode_ci有什么区别呢?在编程语言中,通常用unicode对中文字符做处理,防止出现乱码,那么在MySQL里,为什么大家都使用utf8_ ...

  9. utf8_unicode_ci、utf8_general_ci区别

    摘录一下Mysql 5.1中文手册中关于utf8_unicode_ci与utf8_general_ci的说明:   当前,utf8_unicode_ci校对规则仅部分支持Unicode校对规则算法.一 ...

随机推荐

  1. c++ abs与fabs

    在stdlib.h中定义的abs只针对整数取决对值,如果要对浮点数取绝对值,应该用fabs(或fabsf). 而math.h中定义的abs是可以对浮点数取绝对值的. 所以如果包含了stdlib.h和m ...

  2. spine findBone

    spBone* bone=skeletonAnimationNode->findBone("boneName"); CCPoint boneWorldPos=ccp(bone ...

  3. ATITIT.翻译模块的设计与实现 api attilax 总结

    ATITIT.翻译模块的设计与实现 api attilax 总结 1. 翻译原理1 2. TMX格式是国际通用格式(xml)1 2.1. 方法/步骤2 3. TRADOS2 4. ATITIT.翻译软 ...

  4. WCF问题集锦:未依照DataMember定义的名称序列化对象

    今遇到WCF序列化BUG,代码例如以下: /// <summary> /// 包括数据的返回对象 /// </summary> /// <typeparam name=& ...

  5. 热烈祝贺阿尔法Go首战告捷

    这是人类的一大杰作和进步.一个国家和民族的未来在科技,靠造房子是成不了科技强国的. 当然,也要祝贺一下北上深房价突破历史高位.这也是伟大而不朽的成果.

  6. WEB前端面试题 分别使用2个、3个、5个DIV画出一个大的红十字

    <!DOCTYPE html> <!--两个DIV--> <html> <body> <div style="width:100%;he ...

  7. Compiler Error C2872: ambiguous symbol

    参考资料:http://blog.csdn.net/greytree/article/details/354530 刚才写的程序报错ERROR C2872(CL.exe)原因很简单 ZThread有定 ...

  8. VMWare虚拟机端口转发

    # VMWare虚拟机端口转发 虚拟机和宿主机共用主机IP对外提供服务,又不想提供给虚拟机独立IP,使用VM虚拟机提供的端口转发功能正合适. ### 端口转发--------------------- ...

  9. Oracle面试题目及解答

    这里的回答并不是十分全面,这些问题可以通过多个角度来进行解释,也许你不必在面试过程中给出完全详尽的答案,只需要通过你的解答使面试考官了解你对ORACLE概念的熟悉程度. 1. 解释冷备份和热备份的不同 ...

  10. 查看网络连接数目(解决TIME_WAIT过多造成的问题_转)

      转自:解决TIME_WAIT过多造成的问题 (eroswang的csdn) #netstat -n | awk '/^tcp/ {++S[$NF]} END { for(a in S) print ...