What problem does it solve?
This Skill provides advanced strategies and patterns for building, optimizing, and managing PostgreSQL databases in production environments, moving beyond basic schema design.
Core Features & Use Cases
- Data Type Optimization: Guidance on choosing the most efficient data types (UUID, JSONB, ARRAY, ENUM, INET).
- Indexing Strategies: Detailed explanations and examples for B-tree, GIN, GiST, BRIN, partial, and expression indexes.
- Query Optimization: Techniques using
EXPLAIN ANALYZE, CTEs, and window functions.
- Partitioning: Implementing range and list partitioning for large tables.
- Full-Text Search: Leveraging
tsvector, tsquery, and pg_trgm for efficient text searching.
- Connection Pooling: Recommendations for using PgBouncer.
- Backup Strategies: Overview of
pg_dump, pg_basebackup, and WAL archiving.
- Row-Level Security: Implementing multi-tenant data isolation.
- Essential Extensions: Usage of
pg_trgm, pg_stat_statements, and postgis.
Quick Start
Use the postgresql skill to create an index on the 'created_at' column of the 'orders' table.