Guided Notes
Creating Databases & Tables
CREATE and DROP DATABASE, CREATE TABLE with MySQL data types, ALTER TABLE, DROP and TRUNCATE, and choosing the right types.
Databases
Slide 1 / 5A MySQL server hosts many databases (also called schemas):
CREATE DATABASE shop; CREATE DATABASE IF NOT EXISTS shop; SHOW DATABASES; USE shop; -- make it the current database DROP DATABASE shop; -- deletes it and every table inside — permanently
Set a character set for full Unicode (including emoji): CREATE DATABASE shop CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci;
