The MySQL working environment was previously configured, but there are also missing files that can be manipulated, i.e. a database and 5 tables are missing.
Download the relevant code
Download the relevant files in the URL http://www.forta.com/books/0672325675/, where I downloaded the MySQL (and MariaDB) SQL scripts.
After downloading, there will be two files: Create.txt and Populate.txt.
Establishment of the database
Input in MySQL: CREATE DATABASE orderdb;
Do not forget the semicolon, which is the syntax of MySQL.
In addition, MySQL is not sensitive to case, so it can also be used: Create DATABASE Orderdb;
You can then press ENTER to create a successful build. You can enter the command: show databases; you can see the ORDERDB database, but now the library is empty.
The establishment of tables in the database
Input mysql> use Orderdb;
Will enter the ORDERDB database.
Then, we follow the downloaded two files, step into the code and run (enter), where the Creat.txt code is the establishment of the table, populate is the data fill.
Note that when we paste the code, the--and the text behind it--doesn't have to be glued in.
End
After the establishment is complete, we will be able to follow the necessary knowledge of the order of the textbook training.
SQL must be known to initialize data