Relational Operators Flashcards

(9 cards)

1
Q

What is a relational operator?

A

A query language that allows tuples to be retrieved and updated in one statement without looping.

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

What are the five fundamental operations?

A

Selection, projection, cartesian product, union and set difference.

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

What are the Unary Operations?

A

Selection - works on a single relation R and defines a relation that contains only those tuples of R that satisfy the specified condition.

Projection - extracts the values of specified attributes and eliminating duplicates.

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

What are the set operations?

A

Union, Set difference, cartesian product, intersection and join.

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

What does a union operation do?

A

These contains all the tuples of R and S with duplicates eliminated. It is only possible if the two schemas have the same number of attributes.

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

What does a set difference operation do?

A

This defines a relation consisting of the tuples that are in R but not in S.

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

What does a intersection operation do?

A

This consists of the set of all tuples that are in both R and S.

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

What does a cartesian product operation do?

A

This multiplies two relations to define another relation consisting of all possible pairs of tuples from the two relations.

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

What are the six types of join operations?

A

Theta, equijoin, natural, outer, semi and division.

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