Zampanò
Zampanò

Reputation: 594

Assistance Implementing A Business Rule in an Entity Relationship Diagram

In a hypothetical scenario where a business requires people to have a membership to use their service, there are three types of memberships: student, corporate, and individual. Student membership is free, but corporate and individual memberships incur a fee.

In order to implement this on an entity relationship diagram, would the following be appropriate?:

enter image description here

This solution utilizes subtypes/supertypes, with students, corporate, and individuals being subtypes of the membership supertype.

If there is a more appropriate way to handle this, please provide it. I am trying to learn the best practices for database design.

Upvotes: 0

Views: 74

Answers (1)

Walter Mitty
Walter Mitty

Reputation: 18940

In standard ER modeling, the situation you describe is called generalization/specialization. Students memberships, Corporate memberships, and Individual Memberships are all specialized forms of memberships. In ER diagrams (actually EER diagrams) this is depicted as follows: Diagram

This diagram is for a different case from yours, but the concept of generalization is the same.

Upvotes: 1

Related Questions