Relational Data Storage
In this module you will be introduced to the relational model for data storage. Relational databases store data in interconnected tables (called relations) that are accessed through the imperative query language SQL. Relational (or SQL) databases are the most common data storage form other than text files. Text files reach their limit when records reach into the hundreds or low thousands, while relational databases can accommodate millions of records. This lesson introduces the design and structure of relational databases and shows how to data can be stored in a relational format. It also explains how to craft SQL queries to retrieve data for analytics.
Objectives
Upon completion of this lesson, you will be able to
Upon completion of this lesson, you will be able to
- describe the relational data model and relational databases
- design normalized relational databases
- use modeling languages to describe relational structures
- create SQL queries to retrieve data
- insert, update, and delete data records
- distinguish between OLAP and OLTP databases
- build relational databases in SQLite
- access SQLite databases from R
Required Readings
- Chapters 10 - 12 of textbook
Example Code
- SQLite Databases: CoffeeDB.sql | CoffeeDBdata.sql | CoffeeDB - ERD | tradeDB SQL | Student DB with SQL Command in R
Suggested Readings