In one sentence
Students choose the right database, work with data stores, Airtable and Postgres, and build a secure mini-CRM.
Preparation before the session
Time plan
- 00:00โ00:15 Review + the midterm exam
- 00:15โ00:40 Why a database? Sheets vs. a DB
- 00:40โ01:05 Make's data stores
- 01:05โ01:20 โ Break
- 01:20โ01:45 Airtable
- 01:45โ02:15 A little SQL + Supabase
- 02:15โ02:50 Building together: a mini-CRM
- 02:50โ03:00 Summary and practice
Lecture parts and activity type
| Part | Activity type |
|---|---|
| Sheets vs. a database | Comparison |
| Data stores and data structures | Demo |
| Airtable โ a CRM people love | Demo |
| A little SQL | Demo in the SQL Editor |
| Make + Supabase / Postgres | Explanation + simulation |
| Building together: a mini-CRM | Building together |
The 3 messages that must get across
- The tool by the need.
- Parameters always.
- One source of truth.
Questions for class discussion
- Where in your organization is there a "sheet that became a system"?
- Who needs to see data and who needs to edit it?
- What's the risk in a two-way sync?
Live demo script
A data store as memory
- Data structure โ Data stores โ Add data store โ Data structure: Add โ fields.
- In the scenario โ After the clean-up: Data store โ Get a record (key: email).
- Filter โ count Does not exist.
- Update โ Add/replace a record: key email, count = ifempty(โฆ)+1, firstSeen = ifempty(โฆ; now).
An Airtable CRM
- Base โ Contacts (Name, Email, Company), Deals (Name, Contact โถ link, Stage, Value).
- Token โ airtable.com/create/tokens โ scopes data.records:read/write, schema.bases:read โ Base.
- Upsert โ Airtable โ Upsert a Record (or Search โ Router โ Create/Update).
- Deal โ Airtable โ Create a Record โ Contact: an array with the id.
Supabase + an API
- Table โ Supabase โ SQL Editor โ CREATE TABLE.
- Connection โ PostgreSQL โ Execute a query โ Add connection (Database details โ Connection string).
- POST โ Webhook โ auth โ Execute a query with parameters โ Create JSON โ 201.
- GET โ Webhook โ select * from deals where email = $1 โ Array aggregator โ Router 200/404.
Problems students will run into
| Problem | Quick fix |
|---|---|
| Get a record stops when there is no record | In the settings: make sure the module returns an empty bundle, or use Check the existence. |
| The key doesn't match | Capital letters/spaces. |
| INVALID_MULTIPLE_CHOICE_OPTIONS | A Stage value that doesn't exist in the single select. |
| 403 | The token wasn't given access to this base. |
| connection refused / timeout | Wrong host/port or SSL off. |
| permission denied for table | The connection's user has no permissions โ use postgres or set up GRANT. |
| Telegram was sent 4 times | The Text aggregator is missing. |
| total arrives as text | Postgres numeric โ parseNumber. |
Tips from the classroom
- Connecting Postgres to Supabase is the hurdle โ prepare a ready connection string.
- Demonstrate SQL injection on a test database.
- The Increment function is a pleasant surprise.
Adapting to different levels
For students who struggle: A data store + Airtable only.
For fast students: RPC and the stage history.
Answer key โ multiple-choice questions
Students see the answers in shuffled order, so the key gives the wording of the right answer.
| # | Right answer |
|---|---|
| 1 | A small table inside Make with a key and a data structure |
| 2 | A relation between records in different tables |
| 3 | SELECT stage, SUM(value) FROM deals GROUP BY stage |
| 4 | In a connection / Keychain |
| 5 | Returns the new record's id |
| 6 | When there is a lot of data, relations, and parallel work |
| 7 | Whether a key exists (Boolean) |
| 8 | Filters on Airtable's side |
Homework
- An active mini-CRM.
- Preparing for session 9: create an API key at OpenAI or Anthropic (or make sure you have access to the Make AI Provider). A Gmail account with 10 sample emails.