SQL3 Statement Classes

Comparing statement classes further delineates SQL3 from SQL92. However, the older terms are still used, so readers need to know them. SQL92 grouped statements into three broad categories:

Data Manipulation Language (DML)

Provides specific data-manipulation commands such as SELECT, INSERT, UPDATE, and DELETE

Data Definition Language (DDL)

Contains commands that handle the accessibility and manipulation of database objects, including CREATE and DROP

Data Control Language (DCL)

Contains the permission-related commands GRANT and REVOKE

In contrast, SQL3 supplies seven core categories, now called classes, that provide a general framework for the types of commands available in SQL. These statement “classes” are slightly different from the SQL92 statement categories, because they attempt to identify the statements within each class more accurately and logically and they provide for the development of new features and statement classes. Additionally, the new statement classes now allow some “orphaned” statements that did not fit well into any of the old categories to be properly classified.

Table 1-1 identifies the SQL3 statement classes and lists some of the commands in each class, each of which is fully discussed later. At this point, the key is to remember the statement class titles.

Table 1-1. SQL3 statement classes

Class

Description

Example commands

SQL connection statements

Start and end a client connection

CONNECT, DISCONNECT

SQL control statements

Control the execution of ...

Get SQL in a Nutshell, 3rd 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.