ER, EER Diagram Notation: Entities, Participation, Cardinality and Constraints for CSIR NET JRF

Download PDF of This Page (Size: 254K)

Image of Strong Entities

Image of Strong Entities

Image of Strong Entities

Image of Weak Entities

Image of Weak Entities

Image of Weak Entities

Image of Attributes

Image of Attributes

Image of Attributes

Image of multi valued Attributes

Image of Multi Valued Attributes

Image of multi valued Attributes

Image of Composite Attributes

Image of Composite Attributes

Image of Composite Attributes

Image of Relationships

Image of Relationships

Image of Relationships

Image of Identifying Relationships

Image of Identifying Relationships

Image of Identifying Relationships

Image of N-ary Relationships

Image of N-Ary Relationships

Image of N-ary Relationships

Constraints - Participation

Total Participation - entity X has total participation in Relationship Z, meaning that every instance of X takes part in AT LEAST one relationship. (i.e. there are no members of X that do not participate in the relationship.

Example: X is Customer, Y is Product, and Z is a ‘Purchases’ relationship. The figure below indicates the requirement that every customer purchases a product.

Image of Total Participation Relationships

Image of Total Participation Relationships

Image of Total Participation Relationships

Partial Participation - entity Y has partial participation in Relationship Z, meaning that only some instances of Y take part in the relationship.

Example: X is Customer, Y is Product, and Z is a ‘Purchases’ relationship. The figure below indicates the requirement that not every product is purchases by a customer. Some products may not be purchased at all.

Partial participation

Partial Participation

Partial participation

Constraints - Cardinality

1:N – One Customer buys many products, each product is purchased by only one customer.

Image of Constraints - Cardinality 1: N

Image of Constraints - Cardinality 1: N

Image of Constraints - Cardinality 1: N

N:1 - Each customer buys at most one product, each product can be purchased by many customers.

Image of Constraints - Cardinality N:1

Image of Constraints - Cardinality N:1

Image of Constraints - Cardinality N:1

1:1 – Each customer purchases at most one product, each product is purchased by only one customer.

Image of Constraints - Cardinality 1: 1

Image of Constraints - Cardinality 1: 1

Image of Constraints - Cardinality 1: 1

M:N – Each customer purchases many products, each product is purchased by many customers.

Image of Constraints - Cardinality M: N

Image of Constraints - Cardinality M: N

Image of Constraints - Cardinality M: N

Specialization/Generalization

Each subclass inherits all relationships and attributes from the super-class.

Image of Specialization Generalization

Image of Specialization Generalization

Image of Specialization Generalization

Constraints on Specialization/Generalization

Total Specialization – Every member of the super-class must belong to at least one subclass. For example, any book that is not a text book, or a novel can fit into the “Other” category.

Image of Total Specialization

Image of Total Specialization

Image of Total Specialization

Partial Specialization – each member of the super-class may not belong to one of the subclasses. For example, a book on poetry may be neither a text book, a novel or a biography.

Image of Partial Specialization

Image of Partial Specialization

Image of Partial Specialization

Disjointness Constraint

Disjoint – every member of the super-class can belong to at most one of the subclasses. For example, an Animal cannot be a lion and a horse, it must be either a lion, a horse, or a dog.

Image of Disjoint

Image of Disjoint

Image of Disjoint

Overlapping – every member of the super-class can belong to more than one of the subclasses. For example, a book can be a text book, but also a poetry book at the same time.

Image of Overlapping

Image of Overlapping

Image of Overlapping

Multiple Inheritance – a subclass participates in more than one subclass/super-class relationship, and inherits attributes and relationships from more than one super-class. For example, the subclass Mermaid participates in two subclass/super-class relationships, it inherits attributes and relationships of Animals, as well as attributes and relationships of Humans.

Image of Multiple inheritance

Image of Multiple Inheritance

Image of Multiple inheritance

Union – a subclass/super-class relationship can have more than one super-class, and the subclass inherits from at most one of the super-classes (i.e. the subclass purchase will inherit the relationships and attributes associated with either service or product, but not both). Each super class may have different primary keys, or the same primary key. All members of the super-classes are not members of the super-class. For example, a purchase can be a product, or a service, but not both. And all products and services are not purchases.

Image of Union Purchase

Image of Union Purchase

Image of Union Purchase

Developed by: