1. Download MySQL
1. Find the official download address of MySQL
https://www.mysql.com/cn/downloads/
2. After opening the page, scroll to the bottom and find the download location.
(点击MySQL Community (GPL) Downloads »)
3. Find the version you want to download, I am windows so choose MySQL Installer for Windows
4. Click to enter and you can see the latest version.
Click Download to download!
If you want to download other versions, click Archives
You can choose the version you want to download.
5. After clicking Download, you will enter the page below. You can log in or register an account. Of course, if you want it to be the easiest, just click No thanks, just start my download.
and you will be able to download without logging in!
(At this time, please note that you can log in to the accelerator when downloading, otherwise it will be a bit slow)
2. Install MySQL
1. Double-click the downloaded .msi installation package and click Run
2. Select an installation type
“Developer Default” is the developer default
“Server only” is installed only as a server
“Client only” is installed only as a client a>
“Full” is a complete installation
“Custom” is a custom installation
This is to install some products and functions. I directly install them by default as a developer.
3. Install the products and features you just selected
4. After the installation is complete, next
5. Click next again
The default port of the database here is 3306. Just select the default developer computer for the setting type here.
6. Click next again
7. Click next to enter the password
8. Click next again
9. Just go all the way to next
10. Enter the password you just entered, and then click check. If the password passes, you can proceed to the next step.
Then proceed all the way to next to complete the installation package installation.
11. After the installation is complete, search for MySQL 8.0 Command Line Client on the start interface and click to open it.
12. Enter the password you just set
13. When the following interface appears, it means the installation has been successful.
3. Configure environment variables
1. Open the folder and find your installation directory
(I installed it by default, so it is under the C drive. Generally, I just find the bin file under the MySQL Server folder, and then copy the directory)
2. Copy directory
3. Open system environment variables
Right click on This PC (My Computer) and click Properties
4. Find "Advanced System Settings" and click "Advanced" environment variables
5. Find the path in "System Variables", click to select the path and click Edit
6. Copy the path you just copied into it
7. Then verify whether the environment variables are configured successfully. Windows + r and enter cmd to open the windows command window.
8. Enter mysql -u root -p, press Enter and then enter the password. If the following interface appears, the system environment variables are configured successfully.
I installed it by default. You can see that MySQL Workbench 8.0 CE is also installed by default. This software has a visual graphical interface with similar functions to navicat and can be operated by yourself.