mysql在安装时如果没指定编码为utf-8,则在使用source命令导入脚本时,记录中的中文会变成乱码,解决方式如下:
mysql -uroot -p --default-character-set=utf8
use dbname
source /root/newsdata.sql
参考链接:
mysql在安装时如果没指定编码为utf-8,则在使用source命令导入脚本时,记录中的中文会变成乱码,解决方式如下:
mysql -uroot -p --default-character-set=utf8
use dbname
source /root/newsdata.sql
参考链接:
转载于:https://my.oschina.net/u/914897/blog/389817