Search code examples
erd

Deciphering the relationship between two entities from the ERD


I want to understand the relationship expressed by the following figure:
enter image description here

The o in front of the employee box means zero or one and the | in front of the department means 1 or more. But I am not sure how to express it.
Some things I thought about this could mean:

  • A department can have no employees
  • An Employee can work in one or more departments (Not sure if this is true)
  • A department can have many employees
    Need some input on the above.

Solution

  • This a many to many relationship. The o and the | tell about optional or mandatory elements, more precisely that:

    • a department can have several employees working in it, but could also have none;
    • an employee must work in at least one department, and can work in several.

    By the way, it's worth discovering more about Crow's foot ERD notation