postgres-best-practices

Optimize PostgreSQL queries, schemas, and database configuration.

150|51|Updated Mar 14, 2026
One-click install
npx skills add https://github.com/AratKruglik/claude-laravel --skill postgres-best-practices-aratkruglik
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: postgres-best-practices
Source: https://github.com/AratKruglik/claude-laravel/tree/main/.claude/skills/postgres-best-practices
Command: npx skills add https://github.com/AratKruglik/claude-laravel --skill postgres-best-practices-aratkruglik

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) and references (resource) and assets (resource) components.

What problem does it solve?

This Skill addresses common performance bottlenecks in PostgreSQL databases, helping users write more efficient queries, design better schemas, and configure their databases for optimal speed and stability.

Core Features & Use Cases

  • Query Optimization: Provides rules for indexing, query planning, and avoiding full table scans.
  • Schema Design: Offers best practices for data types, primary keys, and partitioning.
  • Connection Management: Guides on connection pooling, timeouts, and limits to prevent resource exhaustion.
  • Use Case: A developer is experiencing slow query times on their application's user data. They can use this Skill to identify missing indexes or inefficient query patterns and receive concrete SQL examples for improvement.

Quick Start

Use the postgres-best-practices skill to find rules for optimizing slow queries.

Frequently Asked Questions about postgres-best-practices

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

FAQPage Schema
How do I optimize slow PostgreSQL query performance and avoid full table scans?

To optimize slow PostgreSQL query performance, you need proper indexing and query planning. This Skill provides concrete rules to identify missing indexes, avoid full table scans, and rewrite inefficient query patterns for better execution speed.

What are the best practices for PostgreSQL schema design and data type selection?

PostgreSQL schema design best practices involve choosing optimal data types, defining primary keys correctly, and implementing partitioning. This Skill provides actionable rules to review your schema design for efficient data access patterns and structural stability.

How can I configure PostgreSQL connection pooling to prevent resource exhaustion?

Configuring PostgreSQL connection pooling prevents resource exhaustion by managing connection limits and timeouts. This Skill guides you through setting up pooling, configuring timeouts, and enforcing limits to maintain database stability under heavy load.

Does this Skill help with PostgreSQL database monitoring and security configuration?

Yes, this Skill covers PostgreSQL database monitoring and security configuration. It provides best practices for tracking performance metrics, securing data access, and tuning advanced database features to maintain an optimal and safe environment.

What is the best way to tune PostgreSQL database configuration for better concurrency?

The best way to tune PostgreSQL database configuration for concurrency is applying structured rules for resource management and data access patterns. This Skill enables automated configuration tuning to handle concurrent operations efficiently.

Can I use this for automated SQL query optimization and schema review?

Yes, you can use this Skill for automated SQL query optimization and schema design review. It analyzes your database structures and queries against established rules to output concrete SQL examples for immediate improvement.