from utf8 + utf8_general_ci to utf8mb4 + utfmb4_unicode_ci to support smilies to save in my database(MySQL 5.6). I confused because i have data more than VARACHAR(191) and when I converting to utf8mb4 I got Data truncation error. I using InnoDB engine and must to short my VARCHAR(255) to VARCHAR(191) ( 4-byte character encoding in utf8mb4). Does anyone have an idea?
This is Russian chat, if you want to read and write in English, go to the English chat, the link is in the description of this chat
This is because size of varchar is in bytes but smilies and many other Unicode characters can take 4 and sometimes up to 6 bytes. You have to expand your field.
Ty for your answer. I basically do not speak Russian but I can read or I can write in Ukrainian if you want
I can't do this because my fields is indexed before by InnoDB
Ну это попровимо. Удаляешь индекс, меняешь размер поля, создаёшь индекс назад
При смене коллейшена всё равно надо пересоздавать индекс. Так что странно что это может мешать
I don't know if this will do much damage to my database, I have 10 fields to change and a lot of available data. I'm not very strong in MySQL so I'm asking the guru
Тут в чате много украинцев, не менжуйся, пиши по-украински 😂
Обсуждают сегодня