SQL provides an easy, intuitive way to interact with a database. The SQL99 standard does not define the concept of a “database,” but it does define all the functions and concepts needed for a user to create, retrieve, update, and delete data. It is important to review a few of the concepts upon which the SQL standard is based.
Other database manipulation languages, such as Xbase or Visual Basic, perform their data operations quite differently from SQL. These languages require the programmer to tell the program exactly how to treat the data, one record at a time. Since the program cycles down through a list of records, performing its logic on one record after another, this style of programming is frequently called row processing or procedural programming.
SQL programs operate in logical sets of data.
Set theory is applied when the
FROM clause is
used, as in the
SELECT statement. In effect,
data is selected from a set called a table. Unlike the row processing
style, set processing
allows a programmer to tell the
database simply what is required, not
how each individual piece of data should be
handled. Sometimes set processing is referred to as
, since a programmer declares only
what data is necessary, as in “Give me all employees in the
southern region who earn more than $70,000 per year,” rather
than describes the exact procedure used to manipulate the data.
Set theory was the brainchild ...