5.3 Defining the Database: SQL Data Definition Language (DDL)
The most used SQL data definition language (DDL) commands are the following:
CREATE DATABASE
CREATE SCHEMA
CREATE TABLE
CREATE INDEX
ALTER TABLE
RENAME TABLE
DROP TABLE
DROP INDEX
These statements are used to create, change, and destroy the structures that make up the logical model. These commands can be used at any time to make changes to the database structure. Additional commands are available to specify physical details of storage, but we will not discuss them here because they are specific to the system. There are also commands to create and destroy views, which we will discuss in Section 5.5.
5.3.1 CREATE DATABASE, CREATE SCHEMA
In SQL, the command to create a new database ...
Get Databases Illuminated, 4th 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.