Data modelling and ER diagram

Monima Baruah
2 min readJun 20, 2019

--

Database Modelling with open source tool, draw.io (https://www.draw.io/). It has the ability to model databases in an easy-to-read format with ER (entity-relationship) diagrams.

Modelling a database system requires an understanding of relationship and cardinality/multiplicity between entities. One of the following three relationships between two entities exists:

1. One to One

2. One to Many

3. Many to Many

The possible cardinality a table/entity can take in a relationship:

1. One and only one

2. One or many

3. Zero or One or many

4. Zero or one

The Crow Foot Notation Symbols are used with cardinality. The Crow Foot’s symbols and their meaning are given below

A simple example to explain this:

  1. An Employee has one employee card and an employee card has one employee

2. An employee can attend many company events and a company event has many employees

3. An employee has one and only one cubical (if the company has the policy one cube per employee)

4. An employee has one or zero gym pass

5. A manager has many employees but an employee has one manager

6. An employee can have zero or many certifications

Relationships & Cardinalities

1. One-to-One:

a. Patient to Visit

b. Visit Doctor

2. One-mandatory to many-mandatory:

a. Patient to Appointment

3. One-mandatory to many-optional:

a. Doctor to Appointment

b. Bill to Doctor

c. Bill to Payment

d. Bill to Claim

e. Insurance to claim

f. Patient to Insurance

--

--