Relational Algebra and Relational Calculus

To manipulate relations (relational variables), you need some operators. Relations and operators on relations form what is called relational algebra. The collection of relational operators is open ended, but some operators are considered basic. Although the basic operators are somewhat intuitive, I’ll introduce them for the sake of completeness.

Basic Operators

As for simple types, we need at least two operators on relation types: one to store a set of tuples in a relational variable and one to retrieve a variable’s value. These correspond to the familiar notions of assignment and evaluation. The relational selector operator (corresponding to evaluation) returns a table from a relational variable, and the ...

Get Inside Microsoft® SQL Server® 2008: T-SQL Querying 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.