Lecture 8 ERD1
Lecture 8 ERD1
Example:
(Hayes, A-102) depositor
RELATIONSHIP SET BORROWER
RELATIONSHIP SETS (CONT.)
Relationships between more than two entity sets are rare. Most
relationships are binary. (More on this later.)
ATTRIBUTES
Example:
customer = (customer_id, customer_name,
customer_street, customer_city )
loan = (loan_number, amount )
Derived attributes
Can be computed from other attributes
Example: age, given date_of_birth
COMPOSITE ATTRIBUTES
MAPPING CARDINALITY CONSTRAINTS
One to one
One to many
Many to one
Many to many
MAPPING CARDINALITIES
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
ONE-TO-MANY RELATIONSHIP
Employee may have attributed Id, name, street, city , tel-number. The
telephone number is multivalued attribute.