Week 3

Overview

The focus this week is:

  • more server-side development
  • using databases for persistence
  • data modelling entity relationships
  • the SQL query and manipulation language
  • migrations and seeding the DB with data
  • calling async functions that use Promises

This week we'll be swapping out the file-based persistence we used last week for a storage solution that scales to many users over a long period of time: Databases! After we come to terms with basic database concepts, we'll connect a database to our server-side application and learn how to save and retrieve data to and from it.

Core concepts

  1. Databases
  • Entities (tables)
  • Fields (columns)
  • Records (rows)
  1. Relationships
  • Private & foreign keys
  • Joins
  1. Data operations with SQL (CRUD)
  • Create
  • Read
  • Update
  • Delete
  1. Management tools
  • Migrations
  • Seeding
  • Graphical tools
  1. Promises vs async/await

Learning outcomes

By the end of this week you should be able to:

  • explain the advantages databases have over direct file storage
  • explain the relationship of entities, fields, and records
  • maintain a database by creating and running a DB migration
  • seed a database with initial set of data
  • perform CRUD operations with SQL
  • write a query that returns data from more than one DB entity
  • use and deploy database code with your web application