CREATE DATABASE [IF NOT EXISTS] database_name

Description: Creates a database with the name database_name. Specifying IF NOT EXISTS suppresses an error if a database already exists with that name.

Description in: Day 6

See also: DROP DATABASE

Get Sams Teach Yourself MySQL in 21 Days, Second Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.