CodeRigor

COURSE / REAL PRACTICE

From SQLite to PostgreSQL

Move a small notes application from an actual SQLite fixture to an owned local PostgreSQL cluster, with versioned migrations, parameters, transactions and full-row reconciliation.

Lessons & exercises7 authored lessons3 units
Start with the first lesson.

Read the explanation and diagrams, then work through the practice. Your browser profile supplies your saved progress.

What you’ll work toward

Migrate an actual SQLite notes fixture into PostgreSQL using a maintained Go driver, repeatable checksum-checked migrations and explicit transaction/connection lifetimes. Reconcile complete rows, inspect real constraints and verify owned-cluster cleanup.

Read an explanation, inspect the diagrams and work through the available checks, debugging exercises and builds. Feedback and prerequisite links guide the next step.

Before you start

This course builds on these skills:

Individual lessons can add prerequisites. Your lesson progress shows your actual readiness.

A look inside the first lesson

Compare embedded storage with a database server

Go
package main
import ("fmt")
func main(){
fmt.Println("SQLite:","process + owned file")
fmt.Println("PostgreSQL:","application + connection + server")
}

Your lesson sequence

Follow the same units and lessons in either view. Prerequisite links and your practice progress stay with each lesson.

UNIT 013 lessons A different database boundary
  1. LESSON 01.01

    Compare embedded storage with a database server

    Separate a process-owned SQLite file from an application-owned connection to a separately running server.

    Open lesson
  2. LESSON 01.02

    Own an isolated local PostgreSQL lab

    Build an explicit Unix-socket URI for a new owned lab; avoid inherited production destinations.

    Open lesson
  3. LESSON 01.03

    Translate values, constraints and generated identities

    Convert integer flags, exact cents and declared timestamp precision into canonical typed records.

    Open lesson
UNIT 023 lessons Controlled changes and application access
  1. LESSON 02.01

    Plan versioned checksum-checked migrations

    Accept an exact applied migration prefix and reject drift, gaps or unknown future history.

    Open lesson
  2. LESSON 02.02

    Bind parameters and make writes atomic

    Preserve the operation error, clean up failed transactions and keep names in parameter arguments.

    Open lesson
  3. LESSON 02.03

    Own pools and bounded query contexts

    Reuse one bounded pool and preserve parent cancellation/deadlines when setting query timeouts.

    Open lesson
UNIT 031 lesson Prove the migrated application
  1. LESSON 03.01

    Reconcile the actual migrated application

    Compare every canonical row by identity and fields, then challenge real PostgreSQL migrations and writes.

    Open lesson