An Entity-Relationship (ER) model is a high level conceptual data model used to design the logical structure of a database. It represents real world objects as entities and the connections between them as relationships. ER models are typically drawn as ER diagrams to serve as a design blueprint before writing code.


1. Entity
An entity is an object, person, place, or concept that exists independently in the real world and about which we store data. It has a set of attributes that describe its properties and can be uniquely identified when required.
- Notation: Represented by a Rectangle. Example: ‘[Student]’, ‘[Course]’, ‘[Employee]’.
- Weak Entity: An entity that cannot be uniquely identified by its own attributes alone and depends on a strong entity. Represented by a Double Rectangle.
2. Attribute

Attributes are the specific properties or details that describe an entity.
- Notation: Represented by an Oval (Ellipse) connected to the entity. Example: A ‘[Student]’ entity might have attributes like (Roll_No), (Name), and (Branch).
- Key Attribute: The attribute that uniquely identifies each entity record. The text inside the oval is underlined.
3. Relationship

A relationship represents an association or link between two or more entities. It shows how entities are related to or interact with each other in the real world.
- Notation: Represented by a Diamond. Example: A student ‘Enrolls’ in a course: ‘[Student] —< Enrolls > — [Course]’ .