PostgreSQL with Effect SQL
PostgreSQL for the Effect stacks (typescript-api, react-router, astro-fullstack): Docker Compose dev and test databases, migrations run by an explicit command, a scoped connection pool, a schema-decoding repository behind an Effect service, and tests on a private database per test file.
Category: service
In your existing repository
Ask your agent to check compatibility, follow this fragment’s brief, and verify the resulting project. What happens next
- Applies to:
- typescript-api, astro-fullstack, react-router
- Requires tools:
- docker
- Conflicts with:
- drizzle-postgres
Add to your project
Paste the prompt into the coding agent working on your project.
View prompt
Or use the terminal
npx @steamfield/stacks add effect-sql-postgres| Step | Phase | Layer | Command |
|---|---|---|---|
| db-up | setup | install | bun run db:up |
| db-migrate | setup | install | bun run db:migrate |
| test-db | check | test | bun run test:db |
Use with a new stack
Starting fresh instead? These stacks support this fragment.
- astro-fullstackoptional
npx @steamfield/stacks new astro-fullstack --with effect-sql-postgres - react-routeroptional
npx @steamfield/stacks new react-router --with effect-sql-postgres - typescript-apioptional
npx @steamfield/stacks new typescript-api --with effect-sql-postgres
Files
- docs/guidance/effect-sql-postgres/index.md
Usage
Among stacks projects in the 28 days through 30 Oct 2026: Project count: not enough runs yet; Green rate: not enough runs yet.
Weekly projects by stack
Projects whose final fragment set included this fragment, grouped by stack.
Not enough published observations yet.
Not enough published observations yet.
Stacks projects per UTC week through 30 Oct 2026. Published stack counts only.
Data table
| Week ending | Stack | Projects |
|---|---|---|
| 5 Jul 2026 | astro-fullstack | – |
| 12 Jul 2026 | astro-fullstack | – |
| 19 Jul 2026 | astro-fullstack | – |
| 26 Jul 2026 | astro-fullstack | – |
| 2 Aug 2026 | astro-fullstack | – |
| 9 Aug 2026 | astro-fullstack | – |
| 16 Aug 2026 | astro-fullstack | – |
| 23 Aug 2026 | astro-fullstack | – |
| 30 Aug 2026 | astro-fullstack | – |
| 6 Sept 2026 | astro-fullstack | – |
| 13 Sept 2026 | astro-fullstack | – |
| 20 Sept 2026 | astro-fullstack | – |
| 27 Sept 2026 | astro-fullstack | – |
| 4 Oct 2026 | astro-fullstack | – |
| 11 Oct 2026 | astro-fullstack | – |
| 18 Oct 2026 | astro-fullstack | – |
| 25 Oct 2026 | astro-fullstack | – |
| 5 Jul 2026 | react-router | – |
| 12 Jul 2026 | react-router | – |
| 19 Jul 2026 | react-router | – |
| 26 Jul 2026 | react-router | – |
| 2 Aug 2026 | react-router | – |
| 9 Aug 2026 | react-router | – |
| 16 Aug 2026 | react-router | – |
| 23 Aug 2026 | react-router | – |
| 30 Aug 2026 | react-router | – |
| 6 Sept 2026 | react-router | – |
| 13 Sept 2026 | react-router | – |
| 20 Sept 2026 | react-router | – |
| 27 Sept 2026 | react-router | – |
| 4 Oct 2026 | react-router | – |
| 11 Oct 2026 | react-router | – |
| 18 Oct 2026 | react-router | – |
| 25 Oct 2026 | react-router | – |
| 5 Jul 2026 | typescript-api | – |
| 12 Jul 2026 | typescript-api | – |
| 19 Jul 2026 | typescript-api | – |
| 26 Jul 2026 | typescript-api | – |
| 2 Aug 2026 | typescript-api | – |
| 9 Aug 2026 | typescript-api | – |
| 16 Aug 2026 | typescript-api | – |
| 23 Aug 2026 | typescript-api | – |
| 30 Aug 2026 | typescript-api | – |
| 6 Sept 2026 | typescript-api | – |
| 13 Sept 2026 | typescript-api | – |
| 20 Sept 2026 | typescript-api | – |
| 27 Sept 2026 | typescript-api | – |
| 4 Oct 2026 | typescript-api | – |
| 11 Oct 2026 | typescript-api | – |
| 18 Oct 2026 | typescript-api | – |
| 25 Oct 2026 | typescript-api | – |
By stack
How often this fragment stays in a default composition, or gets attached as an option.
Stacks projects · 28 days through 30 Oct 2026. Counts rounded to 5.
Data table
| Stack | Projects | Role | Share |
|---|---|---|---|
| astro-fullstack | – | Optional · attached | 0% |
| react-router | – | Optional · attached | 0% |
| typescript-api | – | Optional · attached | 0% |
Green rate with and without it
This compares projects; it isn't an effect of the fragment.
Not enough runs in this breakdown yet.
Stacks projects · 28 days through 30 Oct 2026. Counts rounded to 5.
Often used with
Co-occurrence above the baseline, within a stack. Required fragment pairs are excluded.
Not enough runs in this breakdown yet.
Stacks projects · 28 days through 30 Oct 2026. Counts rounded to 5.
Computed 31 Oct 2026, through 30 Oct 2026. Numbers describe stacks projects, not the ecosystem.