Entity Relationship Diagram

For our next project we will be creating a website that will be linked to a database that holds data. An entity relationship diagram is a data model that is used to describe the relationships between each entity.

The relationships you can have in an ERD are as follows:

One to One

For example, in the diagram below for each product there is only one supplier and conversely for each supplier there is only one product.

Screen Shot 2015-03-03 at 12.01.59 

One to Many

For example, in the diagram below it is stating that each product has many (more than one) different suppliers.

Screen Shot 2015-03-03 at 12.02.06


After our ERD lecture I was then asked to create a ERD following this criteria:


Create an ERD for a recipe book which would store data to allow:

  *   recipe book contributors to store their personal data (relevant to a cookbook application)

  *   where all contributors are optionally able to create 1 or many recipes

  *   where each recipe has a:

  *   title

  *   contributor

  *   description (including cooking instructions)

  *   where each recipe has 1 or many photos

  *   where each photo is accompanied by a short description

Remember to link the entities as appropriate (using foreign keys).

Below is my Entity Relationship Diagram

Screen Shot 2015-03-03 at 12.02.13

The relationships between each entity are:

Member has One to Many relationship with Recipe

Recipe has One to Many relationship with Photo


Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s