This question already has an answer here:
I'm working on a site which handles user logins through Steam and some usernames can have weird characters in them and whenever I try to update/insert them I get the #1366 - Incorrect string value error. For example I had a query fail because of this:
You need to use utf8mb4 that stands for 4-byte utf8 unicode encoding. You have to make sure:
SET NAMES utf8mb4
before running any queries.More information can be found in: https://dev.mysql.com/doc/refman/5.5/en/charset-unicode-utf8mb4.html