{"enrichment":{"faq":[{"a":"postgres-drizzle teaches you to initialize a PostgreSQL database with Drizzle ORM by installing drizzle-orm and drizzle-kit, configuring your database connection, and defining type-safe schemas. You'll learn to connect via environment variables, set up connection pooling for production, and use drizzle-kit to generate and apply migrations. The skill covers both local development and deployment patterns.","q":"How do I set up type-safe PostgreSQL with Drizzle ORM?"},{"a":"postgres-drizzle explains that drizzle-kit generate creates migration files from your schema changes, while drizzle-kit migrate applies those migrations to your database. Use generate when your schema definition diverges from your database state, then migrate to sync them. The skill covers the push vs. generate vs. migrate workflow and helps you choose the right command for your development stage.","q":"What does drizzle-kit generate migrate do and when do I use it?"},{"a":"postgres-drizzle teaches relational query patterns that prevent N+1 problems by using joins and eager loading instead of fetching parent records then looping to fetch children. You'll learn Drizzle's query builder syntax for left joins, inner joins, and relation helpers to load nested data in a single query. The skill includes examples of slow patterns and their optimized alternatives.","q":"How can I avoid N+1 query problems in Drizzle relational queries?"},{"a":"postgres-drizzle covers query performance diagnosis by using PostgreSQL's EXPLAIN ANALYZE to identify missing indexes, sequential scans, and inefficient join orders. You'll learn to add indexes on foreign keys and frequently filtered columns, recognize N+1 patterns, and use connection pooling to avoid bottlenecks. The skill includes decision trees for common slow-query scenarios.","q":"Why is my Drizzle query slow and how do I diagnose it?"},{"a":"postgres-drizzle teaches many-to-many modeling by creating a junction table with foreign keys to both parent tables, then defining Drizzle relations to query through it. You'll learn schema design patterns, how to insert and query junction records, and when to add extra columns (like timestamps) to the junction table. Examples cover both simple and complex many-to-many scenarios.","q":"How do I model many-to-many relationships in Drizzle ORM?"},{"a":"postgres-drizzle covers connection pooling setup using PgBouncer or native pool options in your Drizzle client, explaining pool size tuning, idle timeout configuration, and deployment patterns. You'll learn why pooling matters for serverless environments, how to monitor pool exhaustion, and best practices for graceful shutdown. The skill includes configuration examples for common hosting platforms.","q":"What connection pooling strategy should I use for Drizzle in production?"}],"shadow_tags":["type-safe-orm","schema-versioning","query-optimization","connection-pooling","relational-data","migration-management","postgres-features","performance-tuning","database-design"],"summary_rewrite":"Build type-safe database applications pairing PostgreSQL with Drizzle ORM. This skill covers schema design, relational queries, migrations via drizzle-kit, connection pooling, and common performance pitfalls like N+1 queries and missing indexes. Includes decision trees for modeling relationships and diagnosing slow queries."},"files":[{"bytes":9829,"path":"skills/postgres-drizzle/SKILL.md","sha256":"b567b8eed243de3214330746240bbd943e5f7dd5485fd3b86e66bc93632e8046","url":"https://skillfed.io/files/ccheney/robust-skills/postgres-drizzle/3b3085fa/SKILL.md"}],"id":"ccheney/robust-skills/postgres-drizzle","links":{"html":"https://skillfed.io/ccheney/robust-skills/postgres-drizzle","md":"https://skillfed.io/ccheney/robust-skills/postgres-drizzle.md","repo":"https://github.com/ccheney/robust-skills"},"meta":{"agents_supported":[],"first_seen":"2026-07-28","forks":3,"language":"JavaScript","last_updated":"2026-07-07","license":"MIT","name":"postgres-drizzle","publisher":"ccheney","stars":55},"relations":{"similar":[{"id":"pedronauck/skills/drizzle-postgres"},{"id":"honra-io/drizzle-best-practices/drizzle-best-practices"},{"id":"giuseppe-trisciuoglio/developer-kit/drizzle-orm-patterns"},{"id":"andrelandgraf/fullstackrecipes/drizzle-queries"},{"id":"triggerdotdev/trigger.dev/drizzle"},{"id":"Mindrally/skills/drizzle-orm"},{"id":"oakoss/agent-skills/drizzle-orm"},{"id":"bobmatnyc/claude-mpm-skills/drizzle"},{"id":"secondsky/claude-skills/drizzle-orm-d1"},{"id":"secondsky/claude-skills/bun-drizzle-integration"}]},"slug":{"owner":"ccheney","repo":"robust-skills","skill":"postgres-drizzle"},"version":"3b3085fa"}
