Recall & Review
beginner
What is a many-to-many relationship?
A many-to-many relationship is when multiple items in one group relate to multiple items in another group. For example, students can enroll in many courses, and each course can have many students.
Click to reveal answer
beginner
How is a many-to-many relationship usually managed in databases?
It is managed by creating a third table, called a junction or join table, that links the two groups together by storing pairs of related items.
Click to reveal answer
beginner
Give a real-life example of a many-to-many relationship.
A real-life example is books and authors. One book can have many authors, and one author can write many books.
Click to reveal answer
intermediate
Why can’t many-to-many relationships be represented directly in simple tables?
Because a single table row can only link one item to one other item per row, many-to-many needs an extra table to connect multiple items from both sides.
Click to reveal answer
beginner
What role does the junction table play in a many-to-many relationship?
The junction table acts like a bridge that holds pairs of IDs from the two related tables, showing which items are connected.
Click to reveal answer
Which of the following best describes a many-to-many relationship?
✗ Incorrect
A many-to-many relationship means many items from one group connect to many items in another.
What is the purpose of a junction table in many-to-many relationships?
✗ Incorrect
The junction table holds pairs of IDs linking items from both groups.
Which example shows a many-to-many relationship?
✗ Incorrect
Students can take many courses, and courses can have many students.
Why can’t many-to-many relationships be stored in just two tables without a junction table?
✗ Incorrect
A single row links one item to one item, so many-to-many needs a third table.
In a many-to-many relationship, what does each row in the junction table represent?
✗ Incorrect
Each row shows a connection between one item from each related group.
Explain what a many-to-many relationship is and how it is represented in databases.
Think about how students and courses relate.
You got /3 concepts.
Describe why a junction table is necessary for many-to-many relationships and what it contains.
Consider how to link multiple items from two groups.
You got /3 concepts.