PostgreSQL Patterns
Optimizes PostgreSQL databases with battle-tested patterns for schema design, index tuning, security policies, and query performance.
PostgreSQL Patterns equips Claude Code with production-ready database best practices derived from Supabase architecture standards. It provides instant guidance on optimal data types, index selection across B-tree, GIN, and BRIN indexes, efficient cursor-based pagination, and SKIP LOCKED job queue implementations. Database developers and backend engineers can use this skill when writing migrations, debugging slow queries via pg_stat_statements, detecting unindexed foreign keys and table bloat, or configuring hardened Row Level Security (RLS) policies.
主要功能
01Strict data type recommendations to avoid common pitfalls like improper UUIDs or float precision errors
0210 GitHub stars
03Pre-configured anti-pattern queries to detect missing foreign key indexes and table bloat
04Optimized Row Level Security (RLS) policies and secure connection configuration templates
05Scalable query patterns for cursor-based pagination, UPSERTs, and worker queues using SKIP LOCKED
06Context-aware index selection covering composite, partial, covering, and GIN/BRIN types
使用场景
01Designing and refactoring PostgreSQL schemas and migrations with high-performance defaults
02Diagnosing and resolving slow queries, dead tuples, and unindexed joins in production environments
03Implementing performant Row Level Security (RLS) policies for multi-tenant and Supabase applications