Overview
This module looks at ways to integrate Python programs with databases and SQL (Structured Query Language). SQL is an ISO/ANSI standard for creating relational databases, and there are a number of widely used implementations, both commercial (e.g. Oracle) and open source (e.g. MariaDB).
Learning Outcomes
After completing this module, students should understand:
-
How to use the sqlite3 module to connect to a database
-
How to load data to the database
-
How to query the database
-
The basics of CRUD operations
Readings
-
Severance, Python for Everybody, Chapter 15: "Using Databases and SQL"
Additional Readings
Historical Background
-
Codd, E. F. (1970). "A Relational Model of Data for Large Shared Data Banks," Communications of the ACM 13.6, 377-87.
Python Resources
-
PEP 249: Python Database API Specification, v2.0
-
Tutorials (all of these cover much the same ground):