I'm trying to allow user to add emoticons to your personal message.
All posts tells me to change default charset, but I already changed my collation and charset to utf8mb4.
ALTER DATABASE mydb CHARACTER SET = utf8mb4 COLLATE = utf8mb4_unicode_ci;
ALTER TABLE mytable CONVERT TO CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci;
ALTER TABLE mytable CHANGE message message VARCHAR(1000) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci;
but when I try:
UPDATE mytable SET message = '' WHERE (`id` = '1');
I still getting the fallowing error:
Incorrect string value: '\xF0\x9F\x92\x97\xF0\x9F...'
What am I still missing?
I'm running all these commands on MySQL Workbench connect to a MySQL 5.7 server.
I Created my database using Docker using Docker-compose.
my-db:
image: mysql:5.7
command: --character-set-server=utf8mb4 --collation-server=utf8mb4_unicode_ci --max-allowed-packet=1073741824
Also I got the fallowing results from mysql variables.
character_set_client utf8
character_set_connection utf8
character_set_database utf8mb4
character_set_filesystem binary
character_set_results utf8
character_set_server utf8mb4
character_set_system utf8
character_sets_dir /usr/share/mysql/charsets/
collation_connection utf8_general_ci
collation_database utf8mb4_unicode_ci
collation_server utf8mb4_unicode_ci