Git + SQL
Objectives
- Introduction to Git
- Introduction to SQL
- Exercises for self-study
Topics
- Git is the version control system these days: We learn what it is and how to use it
- Plenty of simply examples for you to try
- Starting from 'git as a time machine' allowing access to earlier versions of files
- Branches from simple 'will this work' to separating alternate work
- Next are merging, then remote operations, pull requests
- We also get to GitHub, the most promiment and visible hosting site
- GitHub enables social coding and collaboration
- SQL (Structured Query Language) is maybe the most common data processing language
- We will learn the basics of relational daya and schema
- SQL commands:
select;where;select distinct;select limit - SQL command
joinand its variants for combining table - SQL command
group byfor grouped operations
Core Material
Lecture Slides
- Lecture 7 (2025): Git I (and first_steps.sh example code)
- Lecture 8 (2025): Git II (and branching.sh example code)
- Lecture 9 (2025): SQL I (and SQLite examples.tar.gz and DuckDB examples.tar.gz)
- Lecture 10 (2025): SQL II (and SQLite examples.tar.gz and DuckDB examples.tar.gz)
Lecture Videos
The core videos which complement the slides are the (now captioned) versions of the 2021 course. As the captions may obstruct some of the displayed code, we also show the uncaptioned original versions.
- Video 10 (2025): Week 4 (Box), also Video 10 (2025, captioned) (ClassTranscribe)
- Video 11 (2021): Git 'first steps' (Box, captioned) (and first_steps.sh example code), also Video 11 (2021): Git 'first steps' (uncaptioned)
- Video 12 (2021): Git 'branching' (Box, captioned) (and branching.sh example code), also Video 12 (2021): Git 'branching' (uncaptioned)
- Video 13 (2021): Git 'fork and pull request' (Box, captioned), also Video 13 (2021): Git 'fork and pull request' (uncaptioned)
- Video 14 (2024): Week 5 (Box) also Videso 14 (2025, captioned) (ClassTranscribe)
- Video 15 (2021): SQL and SQLite Intro (Box, captioned), also Video 15 (2021) (Box)
- Video 16 (2021): SQL JOIN and GROUP BY (Box, captioned), also Video 16 (2021) (Box)
Extras
- Example git file first_steps.sh
- Example git file branching.sh
- Section 6.1 to 6.4 from The Unix Workbench
- Section 6.5 to 6.6 from The Unix Workbench
Extra Reading Suggestions
- List of Git Tutorials
- git guide (by Roger Dudler)
- Happy Git With R (by Jenny Bryan et al)
- Visual Git Guide
- ohshitgit.com survival tips
- SQL tutorial and 'sandbox for code'
- Another SQL tutorial
- The Rise of SQL short (Aug 2022) IEEE Spectrum piece
- 'SQL Teaching' tutorial
- Some 'Fun facts about SQLite' (Dec 2024)
Further References
Julia Evans
A few of her comics made it onto the lecture slides. Here are some more related to these lectures:
git
These are a bit more advanced than things we covered.
- Change
gitmessage HEADis last commit- Split commit in two
- A SHA refers to same code
mergeconflictmergeconflict tips- Edit a commit
- Committed to wrong branch
- Every commit has a parent
- Detached HEAD
SQL
Some of these are a bit more advanced than things we covered.