Creating the Sample Database - MySQL
To create books in MySQL:
mysqladmin -h host -u user -p create books-p option or press Enter at the password prompt). MySQL creates a new, empty database named books.
localhost, set user to root, and use the password that you assigned to root when you set up MySQL.
mysql -h host -u user -p -f books < books_mysql.sql-f option forces mysql to keep running even if an SQL error occurs. The < redirection operator reads from the specified SQL file. You can include an absolute or relative pathname (see the "Pathnames" sidebar in "Running SQL Programs" in Chapter 1).
mysql displays the results. Ignore the messages about unknown tables — they're caused by the script's DROP TABLE statements, which you'll need to rerun books_mysql.sql later to restore the tables to their original states.
books, see "MySQL" in Chapter 1.
Tips
books_mysql.sql is identical to the standard SQL script books_standard.sql.