add-database-table

Add Drizzle ORM tables with types, migrations, and CRUD helpers.

Updated Dec 5, 2025
One-click install
npx skills add https://github.com/betterbrand/dealflow-network --skill add-database-table
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: add-database-table
Source: https://github.com/betterbrand/dealflow-network/tree/main/.claude/skills/add-database-table
Command: npx skills add https://github.com/betterbrand/dealflow-network --skill add-database-table

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Eases adding new database entities by providing scaffolding for Drizzle tables, types, migrations, and helper functions, reducing boilerplate and ensuring consistency.

Core Features & Use Cases

  • Table Scaffolding: Adds a new table in drizzle/schema.ts with proper fields.
  • Migration & Types: Exports inferred types and provides a migration workflow.

Quick Start

Modify drizzle/schema.ts to add a new table and run npm run db:push.

Frequently Asked Questions about add-database-table

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I add a new table to a Drizzle ORM database?▼

Add a new table in drizzle/schema.ts with proper fields, export inferred types, then run npm run db:push to migrate. The Skill scaffolds table declarations with primary keys, foreign keys, timestamps, and JSON columns following project conventions.

What's the best way to structure Drizzle migrations in TypeScript?▼

Define tables in drizzle/schema.ts with enforced primary and foreign keys, timestamps, and consistent type exports. Run npm run db:push to apply migrations, and use helper functions in server/db.ts for repeatable CRUD workflows.

How do I create junction tables with Drizzle ORM?▼

Junction tables are scaffolded in drizzle/schema.ts with foreign keys linking to related entities. The Skill enforces proper key relationships and type exports, enabling clean many-to-many relationships following project schema patterns.

Can I use JSON columns with Drizzle database tables?▼

Yes, Drizzle tables support JSON columns. The Skill includes JSON column scaffolding in drizzle/schema.ts alongside standard fields, with inferred types exported for type-safe access in your application.

Do I need helper functions in server/db.ts for database operations?▼

Helper functions in server/db.ts reduce boilerplate for CRUD operations. The Skill generates these alongside table scaffolding to provide a repeatable workflow for querying and modifying entities defined in your schema.