MySQL报错解决方案收集
ERROR 1366 (HY000): Incorrect string value: ‘\xE7\x89\xA9\xE7\x90\x86’ for column ‘字段名’ at row 1
- 字符集不匹配导致
- 更改表的字符集和字段的字符集
mysql> alter table c default character set utf8;
更改字段的字符集时,字段名应带上" ` ",键盘上1左边的符号,英文输入下。
alter table c change `cname` `cteache` varchar(200) character set utf8;
mysqldump: [Warning] Using a password on the command line interface can be insecure.
在导出数据库文件时,不能将密码先输入
正确做法: