Overview
Syllabus
Intro
What's an ORM?
Available Python ORMS
User Model
Common Base
Validation
Relationships
Unique Constraints
Multi Column Indexes
Partial Indexing
Functional/Expression Indexing
Connecting to the DB
Inserting Data
Using a Session Context Manager
Session Scoping
Establishing a DB Connection
Connection Pools
Creating the DB
Database Migrations
Database Migration Libraries
Configuration
Creating a Migration
Run the migration
Downgrade the migration
Modify an Existing Table
Modify Data
Problems in the Wild: Lazy Loading
Lazy Loading: What is it?
Lazy Loading: Why is it a problem?
Lazy Loading: Use Eager Load Instead!
Problems in the Wild: Unexpected Query Generation
Review
Questions
Taught by
PyCon US