The character set of the MySQL stored procedure cannot be defined when a parameter is defined in the stored procedure. Therefore, when a stored procedure is called, the global variable character_set_server is read by default, in addition, only the value of the global variable at mysqld startup is read as the default transfer character set in the stored procedure. Therefore, if the data table/field uses the system's default character set (such as latin1), it will not be faulty when calling the stored procedure to update some non-English string fields. However, if the character set of the data table/field is not the default character set of the system (for example, the default value is latin1 and the data table uses utf8), the problem may occur. Solution: add a line in my. cnf (my. ini in windows:
Default-character-set = utf8
Or
Character-set-server = utf8
Or. It does not work if the SET syntax is used in the mysql command line after mysqld is started.