You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I ran across an issue with the MariaDB/MySQL backend.
The old style VARCHAR(255) breaks the database spec if the utf8mb4 charset is used.
utf8mb4 supports the full uft8 range with character sizes up to 4 bytes.
If the default charset of a database is set to utf8mb4, then the database specification of MT breaks because the maximun size for index columns is 1000 bytes. However, if VARCHAR(255) is specified with utf8mb4 the maximum size of that field would be 1020.
This is a problem if emojis are used, for example in titles, author names, and other user editable meta data. Unfortunately, users love using emojis pretty much everywhere ;)
There are two approaches to fix this:
Reduce the field size to 250 and trim existing data if necessary (would not be a problem here).
Have user editable fields with the 255 length in utf8bm4 and downsize them into 255 2-byte utf8 strings for the corresponding index fields. (not sure if that makes sense).
The text was updated successfully, but these errors were encountered:
I ran across an issue with the MariaDB/MySQL backend.
The old style
VARCHAR(255)
breaks the database spec if theutf8mb4
charset is used.utf8mb4
supports the full uft8 range with character sizes up to 4 bytes.If the default charset of a database is set to
utf8mb4
, then the database specification of MT breaks because the maximun size for index columns is 1000 bytes. However, ifVARCHAR(255)
is specified withutf8mb4
the maximum size of that field would be 1020.This is a problem if emojis are used, for example in titles, author names, and other user editable meta data. Unfortunately, users love using emojis pretty much everywhere ;)
There are two approaches to fix this:
Reduce the field size to 250 and trim existing data if necessary (would not be a problem here).
Have user editable fields with the 255 length in utf8bm4 and downsize them into 255 2-byte utf8 strings for the corresponding index fields. (not sure if that makes sense).
The text was updated successfully, but these errors were encountered: