Rechercher dans le manuel MySQL
10.9.1 The utf8mb4 Character Set (4-Byte UTF-8 Unicode Encoding)
The utfmb4
character set has these
characteristics:
Supports BMP and supplementary characters.
Requires a maximum of four bytes per multibyte character.
utf8mb4
contrasts with the
utf8mb3
character set, which supports only
BMP characters and uses a maximum of three bytes per character:
For a BMP character,
utf8mb4
andutf8mb3
have identical storage characteristics: same code values, same encoding, same length.For a supplementary character,
utf8mb4
requires four bytes to store it, whereasutf8mb3
cannot store the character at all. When convertingutf8mb3
columns toutf8mb4
, you need not worry about converting supplementary characters because there will be none.
utf8mb4
is a superset of
utf8mb3
, so for an operation such as the
following concatenation, the result has character set
utf8mb4
and the collation of
utf8mb4_col
:
Similarly, the following comparison in the
WHERE
clause works according to the collation
of utf8mb4_col
:
For information about data type storage as it relates to multibyte character sets, see String Type Storage Requirements.
Document created the 26/06/2006, last modified the 26/10/2018
Source of the printed document:https://www.gaudry.be/en/mysql-rf-charset-unicode-utf8mb4.html
The infobrol is a personal site whose content is my sole responsibility. The text is available under CreativeCommons license (BY-NC-SA). More info on the terms of use and the author.
References
These references and links indicate documents consulted during the writing of this page, or which may provide additional information, but the authors of these sources can not be held responsible for the content of this page.
The author This site is solely responsible for the way in which the various concepts, and the freedoms that are taken with the reference works, are presented here. Remember that you must cross multiple source information to reduce the risk of errors.