Recently, while playing MySQL database, I downloaded a sample from the official
Sakila can be downloaded from http://dev.mysql.com/doc/index-other.html.
I downloaded a zip file containing three sub-files: Sakila-schema.sql, Sakila-data.sql, and SAKILA.MWB.
The installation process is divided into 5 steps:
1. First in the C Packing Directory new folder temp, when you unzip, the Sakila-db folder will appear, including Sakila-schema.sql and Sakila-data.sql files and
Sakila.mwb
2. Connect MySQL server, start cmd, enter CD C:\Program files\mysql\mysql server 5.7\bin
Enter Mysql.exe-hlocalhost-p3306-uroot-p after return
Enter the password after carriage return
3. Enter the source c:/temp/sakila-db/sakila-schema.sql in the shell;
4. Enter the source c:/temp/sakila-db/sakila-data.sql after the return;
5. It's done! Use the SELECT statement to view the database.
You can also see the newly created file under the C:/programdata/mysql/mysql Server 5.7/data folder Sakila
Oneself groping time to take a detour, share to everyone. The first time to write something hehe
How do I install the official MySQL Sakila database?