# Lesson 1: Tables, rows and SELECT In this lesson you'll work through tables, rows and SELECT step by step, with short exercises after each idea. Full lesson: [https://glibcode.net/courses/sql-essentials/lessons/1](https://glibcode.net/courses/sql-essentials/lessons/1) ## Files - `select.sql`: SELECT columns and expressions from one table > **Tip:** Write the FROM and JOIN lines first, then SELECT: it matches how the database reads the query. > **Tip:** `.mode box` and `.headers on` in sqlite3 make results much easier to read. > **Tip:** Count before you delete: run the same WHERE with `SELECT COUNT(*)` first. ## Run it ```sh sqlite3 shop.db < ../../setup/schema.sql sqlite3 shop.db < ../../setup/seed.sql sqlite3 shop.db < select.sql ``` ## Exercises See [exercises.md](exercises.md). Ask in the forum once you've tried.