Database Schema
PostgreSQL 16 · 14 Tables · 7 Migrations
Tables 14
Columns 120+
Indexes 35+
Triggers 9
ERD Diagram
SQL Reference
Commands
Core
Lookup
Streaming
Social
Monetization
Analytics
14
Tables
7
Migrations
9
Triggers
35+
Indexes
3
Enum Types
PostgreSQL 16
Database
Run Commands
# 1. Start database (Docker) docker compose up -d postgres redis # 2. Run all migrations node scripts/migrate.js # 3. Check migration status node scripts/migrate.js --status # 4. Seed dev data (DJs, streams, chat) node seeds/seed-dev.js # 5. Connect to DB (psql) psql postgres://nxondeck:password@localhost:5432/nxondeck # 6. Reset DB (dev only — drops all tables) node scripts/migrate.js --reset # 7. Run integration tests (requires DB) npm run test:integration
Migration Files
users
Click a table to inspect