Install everything you need before your first query. Takes about 20 to 30 minutes. Self-paced, no schedule.
Download the installer, then run it in Terminal. It installs all four tools and creates a retailmart practice database.
Then skip to Verify everything.
Open pgAdmin 4 and create a server with:
| Field | Value |
|---|---|
| Name | PostgreSQL |
| Host | localhost |
| Port | 5432 |
| Username | postgres |
| Password | the one you set |
All three should print a version number. Open pgAdmin 4 from Applications and confirm it connects.
| Problem | Fix |
|---|---|
brew: command not found | Install Homebrew (step 1) |
psql: command not found | Restart Terminal. If still missing: brew link postgresql |
| PostgreSQL won't start | brew services restart postgresql |
| pgAdmin "connection refused" | Check it's running: brew services list |
code: command not found | Open VS Code, press Cmd+Shift+P, run "Shell Command: Install 'code' command" |
Tip: always restart Terminal after installing so the PATH updates.
Download the installer, then run it in an elevated PowerShell (right-click PowerShell, Run as administrator). It installs all four tools and creates a retailmart practice database.
Then skip to Verify everything.
Download the latest Windows (64-bit) installer from EnterpriseDB. Select all components: PostgreSQL Server, pgAdmin 4 and Command Line Tools. Keep the defaults:
| Setting | Value |
|---|---|
| Port | 5432 |
| Username | postgres |
| Password | choose one and remember it |
Check it worked. Open Command Prompt and run psql -U postgres. You should see postgres=#. Type \q to exit. If psql isn't recognised, add C:\Program Files\PostgreSQL\<version>\bin to your PATH.
Get it from code.visualstudio.com. During install, tick Add to PATH and Register Code as editor for supported file types. Useful extensions: SQLTools and SQLTools PostgreSQL.
Get it from git-scm.com. Keep the defaults, but make sure Use Git from the Windows Command Prompt is selected.
All three should print a version number. Open pgAdmin 4 from the Start Menu and confirm it connects.
| Problem | Fix |
|---|---|
psql is not recognized | Add the PostgreSQL bin folder to PATH, or reinstall with Add to PATH |
| Forgot postgres password | pgAdmin 4, right-click the server, Properties, change password |
| PostgreSQL service stopped | Open Services.msc, find postgresql, right-click, Start |
code or git not recognized | Reinstall with Add to PATH checked |
| pgAdmin connection error | Make sure the service is running. Use localhost, port 5432 |
Tip: reboot after installing if a command still isn't recognised.
Once everything is installed, explore the data and get the load script on the dataset page.
Explore the dataset See the curriculum