Relationships between database tables (relational database) Flashcards
What is a One to One Relationship Type?
Visual representation in database design that shows the relationship between two entities, where each entity is uniquely paired with exactly one instance of the other entity.
What is an example of a One to One Relationship Type?
A person can have only one passport
What does a One to One Relationship Type look like?
A straight line with two small lines perpendicular to the straight line at the end of it
What is a One to Many Relationship Type?
Illustrates a scenario where one instance of an entity is associated with multiple instances of another entity, but each instance of the second entity is related to only one instance of the first.
What is an example of a One to Many Relationship Type?
One teacher many students
What does a One to Many Relationship Type look like?
A straight line with one small line perpendicular to the straight line at the end of it and two lines at a 45 degree angle coming out of the perpendicular line on each side of the longest line
What is a Many to Many Relationship Type?
Multiple instances of one entity are associated with multiple instances of another entity.
What is an example of a Many to Many Relationship Type?
A student can enroll into many courses and a course can have multiple students enrolled into it
What does a One to Many Relationship Type look like?
A straight line with two lines at a 45 degree angle coming out of the line at the end of it