Before I thought that MySQL set Utf-8 and nickname Decode after everything, the results only recently found that the 4-byte expression will be an error.
The error message is as follows:
Data:null
message: " ### Error updating database. Cause: java.sql.SQLException: incorrect string value: ' \xf0\x9f\x98\x86\xf0\x9f ' for column ' nickname ' at row 1 ### The error may involve Com.smallfoxdog.demo.mapper.usermapper.insertuser-inline ### the error occurred while setting parameters ### sql: insert into users (Id,wxOpenid,nickName, Avatarurl,gender,province,city,country,continue_days) values (NULL,?,?,?,?,?,?,?, 1) ### cause: java.sql.SQLException: Incorrect string value: ' \xf0\x9f\x98\x86\xf0\x9f ' for column ' nickname ' at row 1 ; uncategorized sqlexception; sql state [HY000]; error code [1366]; Incorrect string value: ' \xf0\ x9f\x98\x86\xf0\x9f ' for column ' nicknAme ' at row 1; nested exception is java.sql.sqlexception: incorrect string value: ' \xf0\x9f\x98\x86\xf0\x9f ' for column ' nickname ' at Row 1 "
status:200
timestamp:1526283581431
__proto__: Object
errmsg: "Request:ok"
Header:object
Solution: 52627223 (Note: He has 2 SQL I failed to execute, but it changed as well)
but look at other posts said the database connection time to remove the encoding format, my link address is as follows, removed the Characterencoding=utf8, Test success
Here is the effect of the modified game has been able to display the expression of the normal
MySQL Error-prone solution (similar to \xf0\x9f\x98\x86\xf0\x9f)