Skip to content

Latest commit

 

History

History
637 lines (350 loc) · 20.3 KB

File metadata and controls

637 lines (350 loc) · 20.3 KB

Class Schedule

Please note that this schedule is subject to change. (And open to pull requests.) Class progress through early materials may warrant a change in the schedule or assigned work.


General weekly schedule:

Tuesday – submit previous week's assignment; quiz by the beginning of class about the assignment; review/discuss/clarify last assignment; introduce new topic and readings Midweek homework - reading assignment
Thursdayquiz by the beginning of class on assigned readings; review quiz results and clarify difficulties revealed by quiz; in‑class partner/small‑group work applying readings; introduce Colab notebook assignment; if time, begin the notebook in class
Weekend homework – Colab notebook
Following Tuesday – submit notebooks; clicker quiz; review/clarify; introduce new topic and readings; etc.

UNIT 1: Relational Databases (MySQL)

Week 1: Thursday, August 21

Prep

In class

  • Introductions and course/unit overview
  • Introduction to SQL and MySQL.
  • Colab warm‑up: connect to MySQL from Python (connector provided), run first SELECT.
  • Query basics: SELECT, WHERE, ORDER BY, LIMIT; basic pattern matching with LIKE and wildcards.
  • Notebook 1 released: "Getting Data Out."

Week 2: Tuesday, August 26

Prep

Reading

  • MySQL Tutorial (PDF): Intro + Basic Queries — pp. 5–7 (mysql-tutorial.pdf on Canvas)

Official MySQL docs

These documentation articles will have more information than you need, and they will reference some things we haven't covered yet. However, it is important to be familiar with them. Glean from them what you need in reference to the assigned notebook and class discussions, and tuck the rest away for later.

Videos (optional)

For reference

  • Master SQL in 16 Pages (on Canvas) — pp. 1–5 (SELECT, WHERE, ORDER BY, LIMIT, LIKE)
  • SQL Cheat Sheet (on Canvas) — pp. 1–2

Assignment

  • Submit Notebook 1 to Canvas by the start of class. The notebook is in Colab, and linked from Canvas under Assignments.
  • Submit Reading Quiz 1 on Canvas under Quizzes (also covers Notebook 1, so be sure to complete Notebook 1 before the quiz).

In class

  • Review Notebook 1 results.
  • Introduce new topic: Aggregation + string/math functions; preview of core joins (INNER, LEFT).

Week 2: Thursday, August 28

Prep

Quiz

Reading Quiz #2 in Canvas (after doing the following readings).

Reading

  • MySQL Tutorial (PDF): pp. 13–25 (mysql-tutorial.pdf on Canvas).

Official MySQL docs

These documentation articles will have more information than you need, and they will reference some things we haven't covered yet. However, it is important to be familiar with them. Glean from them what you need in reference to the assigned notebook and class discussions, and tuck the rest away for later.

Other helpful reference material

Videos (optional)

In class

  • Quiz debrief.
  • Grouping and aggregation practice.
  • If time: begin Notebook 2 in class.

Week 3: Tuesday, September 2

Prep

  • Submit Notebook 2 by the start of class.

In class

  • Review Notebook 2 results.
  • Introduce new topic: Subqueries, CTEs (WITH), and joins.

Week 3: Thursday, September 4

Quiz

Reading Quiz #3 in Canvas (after doing the following readings).

Prep

Primary reading

Official MySQL docs

Other helpful reference material (optional)

  • Master SQL in 16 Pagesp. 6 (subqueries) (Master_SQL_in_16_Pages.pdf on Canvas)
  • Master SQL in 16 Pagespp. 7–9 (JOINS) (Master_SQL_in_16_Pages.pdf on Canvas).
  • Master SQL in 16 Pagesp. 10 (set operations) (Master_SQL_in_16_Pages.pdf on Canvas)

Videos (optional)

Videos are embedded in the primary readings this week. I highly recommend watching them, as well as reading the articles, particularly for any concepts that are new for you.

In class

  • Quiz debrief.
  • Small‑group refactors: rewrite a subquery as a CTE and as a join; compare approaches.
  • Notebook 3 released: Subqueries, CTEs, and basic joins.
  • If time: begin Notebook 3 in class.

Week 4: Tuesday, September 9

Prep

  • Submit Notebook 3 by the start of class.

In class

  • Review Notebook 3.
  • More work on joins.

Week 4: Thursday, September 11

Prep

Quiz

Reading Quiz #4 in Canvas (after doing the following readings).

Primary reading / Official MySQL docs

Short videos

In class

  • Quiz debrief.
  • Install and troubleshoot MySQL and MySQL Workbench on your laptop (if you haven't already).
  • Make and break some database(s).

Supplemental resource:


Week 5: Tuesday, September 16

Prep

Assignment 4

Use the code that AlexTheAnalyst provided to accompany the video we watched, available here, and recreate the Parks and Rec database on your local MySQL instance.

Then write SQL queries that do the following:

  • Show all the tables in the database.
  • Show the schema details for one of the tables.
  • Show the first few records for another table.
  • Write a query that uses a JOIN to combine data from two tables.
  • Write a query that uses an aggregate function (e.g., COUNT, SUM, AVG) and a GROUP BY clause.

For the latter two, they do not need to be anything fancy, but make sure they are original queries (not anything in AlexTheAnalyst's video or his provided code).

Finally, make a screencast video no more than 2 minutes long (preferably less than a minute) in which you show me the database on your machine, and run each of the above queries on it, showing the results.

I recommend writing and testing the queries ahead of time, ensuring that the results match your expectations, and then copying and pasting the queries into the terminal as you make the video, to be nice to your professor. ;)

Submit the video to Canvas by 1:00.

In class

  • Review Assignment 4 and CRUD operations.
  • SOURCE and *.sql files.
  • Pandas to_sql().
  • Introduce database normalization (if time).

Week 5: Thursday, September 18

Quiz

No reading quiz this time, so you can get started on your midterm project.

Prep

Primary reading

In class


Week 6: Tuesday, September 23

Prep

Also...

Primary Reading

In class

  • Primary keys — choosing fields and data types.
  • Generating keys with the IDE.
  • Indexes — choosing fields and creating indexes.
  • Midterm peer feedback, followed by brief work/(re)planning time.

Week 6: Thursday, September 25

Prep

Also...

Official MySQL docs

I have found that combining EXPLAIN with ChatGPT is an immensely helpful combination for database debugging and optimization. You can simply run EXPLAIN and cut-and-paste the output into GPT, or you can ask it a specific question about what you are trying to do and how to fix/improve/optimize it.

In class

  • EXPLAIN walkthroughs.
  • More on indexes.
  • Midterm debugging and feedback, unit wrap‑up.

UNIT 2: NoSQL Databases (MongoDB)

Week 7: Tuesday, September 30

Prep

In class

  • Introduction to Unit 2: NoSQL databases.

Week 7: Thursday, October 2

Prep

Reading Quiz #5 in Canvas (after doing the following readings).

Required Reading

Supplemental Video (optional, but helpful)

Extra resources (optional)

In class

  • Quiz debrief.
  • Practice working with JSON in Python, using data from a public social media API. See JSON practice notebook.

Week 8: Tuesday, October 7

NO CLASS (Kris had Covid)


Week 8: Thursday, October 9

NO CLASS!!!


Week 9: Tuesday, October 14

Prep

  • Install MongoDB on your machine, following the instructions for your OS at Try MongoDB Community Edition.
  • Do Reading Quiz #6 in Canvas (after doing the following readings).

Required Reading

  • NoSQL for Mere Mortals (in Canvas), pp. 153–195.

In class

  • More JSON Practice.
  • Quiz debrief.
  • MongoDB basic operations and testing.

Week 9: Thursday, October 16

Prep

Required Reading

Supplemental Readings (optional, but helpful)

In class

  • Verify working MongoDB installation.
  • MongoDB CRUD operations practice, in mongosh and Python (pymongo) using this notebook.

Week 10: Tuesday, October 21

Prep

  • Complete the Pymongo_Startup.ipynb notebook and submit to Canvas.
  • Reading Quiz #7 in Canvas (after doing the following readings).

Required Reading

In class


Week 10: Thursday, October 23

Prep

  • No reading quiz, but read the following and have it handy in class.

Required Reading

Supplemental Reading (optional)

In class


Week 11: Tuesday, October 28

Prep

  • Complete the Pymongo_Query_Basics.ipynb notebook and submit to Canvas.
  • Reading Quiz #8 in Canvas (after doing the following readings).

NOTE: There is more information in the reading this weekend, especially towards the end of the chapter, than we will interact with in our notebooks and project. Let the quiz guide you regarding what is most important, and we'll reinforce that with our notebook work in class this week.

Required Reading

  • MongoDB, The Definitive Guide: Ch. 7, Introduction to the Aggregation Framework (in Canvas).
  • Aggregation

Pymongo Documentation (optional, but helpful)

In class


Week 11: Thursday, October 30

Prep

  • No required reading or notebook, but review any concepts from the past couple readings that you found challenging in our notebook work on Tuesday.

In class


Week 12: Tuesday, November 4

Prep

  • Complete the Pymongo_Aggregation.ipynb notebook and submit to Canvas.
  • Reading Quiz #9 in Canvas (after doing the following readings).

Required Reading

  • MongoDB, The Definitive Guide: Ch. 4, Indexes (in Canvas).
  • PyMongo documentation: Indexes.

In class


Week 12: Thursday, November 6

Prep

In class


Week 13: Tuesday, November 11

Prep

Required Reading

  • Vector Databases (early release edition): Ch. 1, Introduction to Vector Databases (in Canvas).
  • Vector Databases (early release edition): Ch. 2, Embeddings (in Canvas).

In class


Week 13: Thursday, November 13

Prep

In class


Week 14: Tuesday, November 18

Prep

In class

  • Introduction to Ollama (local AI chatbot) with Ollama test.ipynb.
  • Connecting Ollama to your vector database.

Week 14: Thursday, November 20

Prep

  • Make sure you have all installation issues worked out and can run all cells in the VectorDB notebooks so far. (Exception: if you have issues with ChromaDB, you can ignore/slip those.)

In class

  • FCQs
  • Introducing the final project (local RAG app — an AI chatbot based on a custom vector database).
  • Sentence tokenization (splitting documents into sentences).
  • Final project workshop time.

Week 15: Tuesday, December 2

Prep

In class

  • Hybrid queries.
  • Final project workshop time.

Week 15: Thursday, December 4

Prep

  • Continue work on your final project.

In class

  • Final project workshop time.

Finals week: Wednesday, December 10

Submit your final project to Canvas by 4pm.