Designing the Posts Table: What I Expected vs. What I Got
I sketched three tables before starting. The real project ended up simpler, and one table went unused.
The plan
Before creating the project I wrote down what I expected:
| Table | Fields |
|---|---|
| posts | title, slug, excerpt, body, cover_image, published_at, status |
| tags | name, slug |
| authors | name, bio, avatar |
The result
The posts table has title, excerpt, body, cover_image and tags. Three things I planned as columns turned out to be built in:
- slug is a table option, not a column
- published_at is recorded when a post is published
- status is the draft / published state every content row already has
Tags became a multi-value text column instead of a separate table. An authors table exists, but nothing in posts points to it, so the app ignores it.
Lesson
Check what the platform gives you for free before you design columns for it.