Intro to Relational Algebra Flashcards

1
Q

Structured Query Language

A

SQL: application-level query language, declarative

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

Relational algebra

A

used to represent queries internally, intermediate language used within DBMS

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

RA queries

A

relations are treated as sets, no dupilcates allowed, result is always a relation

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

Unary operation

A

OP [R] => new relation

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

Binary operation

A

[R] Op [S] => new relation

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

Operator precedence

A

Selection
Projection
Cartesian product
Join
Set operations
Parentheses

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

Selection (σ)

A

filter rows based on a condition

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

Projection (π)

A

select specific columns, no duplicate attributes

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

Cartesian product (×)

A

combine all rows from two relations (E)

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

Join (⋈)

A

join relations to form longer tuples (NE). AKA inner join

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

Theta Join

A

general condition with any comparison operator

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

Equijoin

A

equality condition on one or more specified attributes

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

Natural Join

A

equality condition on all common attributes

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

Outer Join variations

A

Left outer join [left + middle]
Right outer join [middle + right]
Full outer join [left + middle + right]

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

Set operations

A

Union, intersection, difference

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

SQL temporary tables

A

allows virtual representation derived from base relations