supabase-postgres-best-practices
来自 Supabase 的 Postgres 性能优化和最佳实践。在编写、审查或优化 Postgres 查询、模式设计或数据库配置时使用此技能。
npx skills add https://github.com/supabase/agent-skills --skill supabase-postgres-best-practices
README 文档
1,391 字Supabase Postgres Best Practices
Comprehensive performance optimization guide for Postgres, maintained by Supabase. Contains rules across 8 categories, prioritized by impact to guide automated query optimization and schema design.
When to Apply
Reference these guidelines when:
- Writing SQL queries or designing schemas
- Implementing indexes or query optimization
- Reviewing database performance issues
- Configuring connection pooling or scaling
- Optimizing for Postgres-specific features
- Working with Row-Level Security (RLS)
Rule Categories by Priority
| Priority | Category | Impact | Prefix |
|---|---|---|---|
| 1 | Query Performance | CRITICAL | query- |
| 2 | Connection Management | CRITICAL | conn- |
| 3 | Security & RLS | CRITICAL | security- |
| 4 | Schema Design | HIGH | schema- |
| 5 | Concurrency & Locking | MEDIUM-HIGH | lock- |
| 6 | Data Access Patterns | MEDIUM | data- |
| 7 | Monitoring & Diagnostics | LOW-MEDIUM | monitor- |
| 8 | Advanced Features | LOW | advanced- |
How to Use
Read individual rule files for detailed explanations and SQL examples:
references/query-missing-indexes.md
references/query-partial-indexes.md
references/_sections.md
Each rule file contains:
- Brief explanation of why it matters
- Incorrect SQL example with explanation
- Correct SQL example with explanation
- Optional EXPLAIN output or metrics
- Additional context and references
- Supabase-specific notes (when applicable)
References
- https://www.postgresql.org/docs/current/
- https://supabase.com/docs
- https://wiki.postgresql.org/wiki/Performance_Optimization
- https://supabase.com/docs/guides/database/overview
- https://supabase.com/docs/guides/auth/row-level-security
同分类其他技能
查看全部 ›中国金融机构数据爬取与分析综合 Skill v12.1.0。2334家/43大类机构名单、60+财经媒体源舆情、 A股报告/公告/研报、
303 99.4万 MysteelAI - 智能问数我的钢铁网(Mysteel)大宗商品价格行情数据查询技能,基于钢联/隆众数据平台提供专业价格数据服务。覆盖黑色金属、有色金属、能源化工、
9 75万 smart-charts32种图表,3 个主题,2步生成: 1.上传数据 — 将 CSV / Excel / JSON 等格式的数据文件拖入对话框; 2.查看结
149 74.3万 论文配图一键生成论文配图一键生成:一条命令从 JSON/CSV/Excel 生成顶刊级学术图表,科研绘图 与期刊配图全场景覆盖。41 种图表(森林图/K
91 52.8万 smart-chartsIntelligent chart generation and data analysis skill. Reads user-sup
2 37.9万 股票/基金/期货量化分析工具全球智能投研工具(stock-researcher)v14.0:多源数据 + 概率预测 + 批量研究 + 可导出报告。 核心能力: -
152 26.5万