Skip to content

Latest commit

 

History

History
68 lines (49 loc) · 3.33 KB

data-models.md

File metadata and controls

68 lines (49 loc) · 3.33 KB

Data Modeling

Projected Time

About 1.5 hour

  • 30 minutes for Lesson
  • 20 minutes for Independent Practice
  • 30 minutes for Guided Practice

Prerequisites

None

Motivation

Data modeling refers to how you organize the data within your database. It involves thinking through the pieces of data your application needs and how those pieces of data relate to each other. Data modeling is the first step to creating a database. Having incorrect data models can cause your application to have inconsistent or inaccurate data, so it's important to code up with data models that will represent your data well.

Objectives

Participants will be able to:

  • become familiar with different types of data models
  • (given a user flow description) identify the necessary data needed as the user moves from page to page
  • (given different types of data or a user flow description) create a data model diagram to show the relationship between data

Specific Things To Teach

  • Introduction to data models/modeling, database models, and databases.
    • Data modeling is the process by which one figures out what data is needed, how it is related, and how it can be defined
    • A database model is a particular type of data model that shows the relationship between data and helps you plan out what needs to be in your database and how the data needs to relate.
    • A database is an organized set of data
  • Data can be related for example: username, first name, last name, email address are all related to the user.
  • Part of data modeling is creating data model representations or schemas showing the relationships between data.

Materials

Lesson

Read through lesson slides Introduction to Data Modles

Guided Practice

Give participants different types of data and work with them to create a diagram that represents the relationship between the data.

An example could be: Imagine you are creating a food website that will have recipes by top chefs from around the world. The following data will be required:

  • recipe name
  • number of ingredients
  • ingredients
  • difficulty level
  • cook time
  • chef (who wrote the recipe)
  • country (where the chef lives)
  • city (where the chef lives)
  • restaurants where the chef has worked
  • chef's favorite ingredient

Create a diagram to show how the data is related.

Independent Practice

Have participants click through a sequence on a website (like Amazon). Have participants list the data that is needed and create a diagram to show how it is related.

Challenge

Participants choose one diagram they made during this lesson and find a different way to represent the relationships between the data.

Check for Understanding

Return to the children in the park and choose the most important data for a website for parents to sign their children up for extracurriculars at the park. Create a database model showing how the data is related.