|
SQL is based largely on relational algebra and tuple relational calculus. Relational algebra, introduced by
E. F. Codd in 1972, provided the basic concepts behind computing SQL syntax. It is a procedural way to construct
data-driven queries, and it addresses the
how
logic of a structured query. The tuple
relational calculus (
TRC
), on the other hand, affects the underlying
appearance of SQL. Relational calculus uses declarative expressions, addressing the
what
logic of a structured query.
There are additional features that set SQL apart from those that merely implement features that are part
of relational algebra or calculus. These features include:
- Support for data insertion, modification and deletion
-
Users are allowed to insert, delete, and modify stored data records.
- Arithmetic operators
-
Arithmetic operations such as addition, subtraction, multiplication, and division (e.g.,
(value1 * 5) + value2) are allowed, as well as comparison operators
(e.g., value3 >= value4).
- Display of data
-
Users may display query-generated relationships (such as a table's contents).
- Assignment
-
Users may rename a relation that is computed by
a query instead of forcing the use of the default relationship name, which may be derived from a column
or function name, depending on the query.
- Aggregate functions
-
User may group related rows together and evaluate averages, sums, counts, maximums, and minimums.
|
|