Https://stackoverflow.com/questions/35125933/mysql-utf8mb4-errors-when-saving-emojis
Character_set_client, _connection, and _results must all is UTF8MB4 for the shortcake to be eatable.
If set NAMES utf8mb4 is executed, all three SET correctly.
A warning that occurs when writing a emoji character to a field in a text type in MySQL. In addition to setting the encoding for Table,column to UTF8MB4, remember to set the encoding for the database connection.
The specified encoding is normal when the program is connected. My MySQL Workbench client could not find a place to set the encoding (Manage Server connection-advanced-others added charset option doesn't seem to work) in MySQL The insert with emoji string in Workbench will report a warning, and the written emoji becomes a question mark, in which case execution is performed before the statement SET NAMES utf8mb4
is written or the query is normal.
MySQL Invalid UTF8 character string