InterviewSolution
Saved Bookmarks
| 1. |
How should data be structured to support Join Operations in a one-to-many relationship? |
||||||||||||||||||||||||||||||||||
|
Answer» Among the most common types of database relationships are the ones involving one-to-many relationships. Consider the example of the Customer and Mobile table. Customer Table:
Mobile Table:
A customer can own many mobile phones, but a mobile belongs to one customer only. Therefore, we've defined the Foreign Key column (Customer_ID) in the Mobile table allowing us to perform SELECT queries with JOIN clauses fairly easily. |
|||||||||||||||||||||||||||||||||||