可以直接从MySQL官方网站下载最新的版本mysql-installer-community-8.0.16.0.msi(64位msi)。
MySQL是跨平台的,选择对应的平台下载安装文件,安装即可。安装时,MySQL会提示输入root用户的口令,请务必记清楚。在Windows上,安装时请选择UTF-8编码,以便正确地处理中文。


至此已下载好mysql安装包。
重启MySQL后,可以通过MySQL的客户端命令行检查编码:
$ mysql -u root -p
Enter password: 
Welcome to the MySQL monitor...
...
mysql> show variables like ‘%char%‘;
+--------------------------+--------------------------------------------------------+
| Variable_name            | Value                                                  |
+--------------------------+--------------------------------------------------------+
| character_set_client     | utf8                                                   |
| character_set_connection | utf8                                                   |
| character_set_database   | utf8                                                   |
| character_set_filesystem | binary                                                 |
| character_set_results    | utf8                                                   |
| character_set_server     | utf8                                                   |
| character_set_system     | utf8                                                   |
| character_sets_dir       | /usr/local/mysql-5.1.65-osx10.6-x86_64/share/charsets/ |
+--------------------------+--------------------------------------------------------+
8 rows in set (0.00 sec)
看到utf8字样就表示编码设置正确。
原文:https://www.cnblogs.com/trnanks/p/10819317.html