Exam Questions and CORRECT Answers
What is the role of a relationship in a database? - CORRECT ANSWER -It connects two
entities.
Which of the following can be an entity name in a database?
- Gender
- Student
- First Name
- Age - CORRECT ANSWER -Student can be an entity name because it is an object with
multiple characteristics, such as name, address, phone number, etc.
What is required in order to use the cartesian product operator on two relations? - CORRECT
ANSWER -It can be applied to any two relations without a requirement.
Consider two relations A and B in a database. Relation A has 5 rows and relation B has 3 rows.
How many rows are produced if we apply the cartesian product operation to A and B? -
CORRECT ANSWER -15 b/c The number of rows created by the cartesian product is
found by multiplying the number of rows in each relation. The new table should have the
columns of BOTH previous tables
Which mathematical operator must be used in order to display information about students who
are majoring in Computer Science but not in Electrical Engineering? - CORRECT
ANSWER -Difference
Which statement about the selection operator is true? - CORRECT ANSWER -It filters
certain tuples in a relation based on given criteria.