update user set name='静宝7721',sex='women' where phone='12345678912';
update user set name='静宝7721',sex='women' where phone='12345678912';
ERROR 1366 (HY000): Incorrect string value: '\xE9\x9D\x99\xE5\xAE\x9D...' for column 'name' at row 1
字符集错误只需要将表的字符集修改即可
方法:
第一步
alter table user default character set utf8;
注释:更改表的编码方式
第二步
alter table user convert to character set utf8;
注释:更改字段的编码方式
网友评论