DBMS-Mapping Cardinalityone-to-one, one-to-many, many-to-one, or many-to-many.pptx

53 views 10 slides Mar 21, 2024
Slide 1
Slide 1 of 10
Slide 1
1
Slide 2
2
Slide 3
3
Slide 4
4
Slide 5
5
Slide 6
6
Slide 7
7
Slide 8
8
Slide 9
9
Slide 10
10

About This Presentation

In database management systems (DBMS), mapping cardinality describes relationships between entities in entity-relationship diagrams. It signifies how instances of one entity relate to instances of another. Cardinality can be one-to-one, where each instance in one entity corresponds to one instance i...


Slide Content

MAPPING CARDINALITY: One-to-one One entity from entity set A can be associated with at most one entity of entity set B and vice versa. 1

EXAMPLE One-to-one relationship: A customer is associated with at most one loan via the relationship borrower A loan is associated with at most one customer via borrower 2

One-to-many One entity from entity set A can be associated with more than one entities of entity set B however an entity from entity set B, can be associated with at most one entity. 3

EXAMPLE In the one-to-many relationship a loan is associated with at most one customer via borrower , a customer is associated with several (including 0) loans via borrower 4

Many-to-one More than one entities from entity set A can be associated with at most one entity of entity set B, however an entity from entity set B can be associated with more than one entity from entity set A. 5

EXAMPLE In a many-to-one relationship a loan is associated with several (including 0) customers via borrower , a customer is associated with at most one loan via borrower 6

Many-to-many One entity from A can be associated with more than one entity from B and vice versa. 7

EXAMPLE: In many to many relationship, A customer is associated with several (possibly 0) loans via borrower A loan is associated with several (possibly 0) customers via borrower 8

Participation of an Entity Set in a Relationship Set Total participation (indicated by double line): every entity in the entity set participates in at least one relationship in the relationship set E.g. participation of loan in borrower is total every loan must have a customer associated to it via borrower Partial participation : some entities may not participate in any relationship in the relationship set E.g. participation of customer in borrower is partial 9

Alternative Notation for Cardinality Limits Cardinality limits can also express participation constraints 10
Tags