Relational Algebra Flashcards
Relational Calculus
Higher level, declarative language for relational Databases
Product of Relational Calculus operation
New Relation
Elements of Relational Calculus
Tuples and Domain
Relational Algebra
A procedural query language, which takes instances of relations as input and yields instances of relations as output
Groups of Relational Algebra
Set theory operations and relational db specific operations
Operations in Relational Algebra Set Ops
UNION, INTERSECTION, DIFFERENCE (MINUS), CARTESIAN PRODUCT (CROSS JOIN)
Operations in Relational DB Ops
SELECT, PROJECT, JOIN, RENAME
Unary Operations
Operations that apply on a single relation (SELECT, PROJECT)
Binary Operations
Operate on two relations by combining related tuples (JOIN)
Aggregate Functions
Operations that summarize data from Tables or Joins (SUM, COUNT)
Selectivity
Fraction of tuples selected by a Selection Condition
Selection Condition
Statement of what data for a Select statement to display
Symbol for SELECT in Relational Algebra
σ
Sigma
Symbol for Relation in Relational Algebra
R
Degree in SELECT
# of attributes in a Relation (Same as the degree of R)
Cascade
Sequence of SELECT statements with a Conjuntive (AND, OR)
Commutative
σ (σ(R)) = σ(σ(R))