The exercises in this appendix are bonus exercises that are specific to MySQL. We provide an explanation or question and then provide sample MySQL-based SQL code to execute. Remember that the SQL code can vary from implementation to implementation, so some of these statements need to be adjusted depending on what system you are working on. Study the question, code, and results carefully to improve your knowledge of SQL.
1. Create a new database for bonus exercises and name it
CREATE DATABASE BONUS;
2. Point MySQL to your new database.
3. Create a table to keep track of basketball teams.
CREATE TABLE TEAMS( TEAM_ID INTEGER(2) NOT NULL, NAME VARCHAR(20) NOT ...