database-operations

Analyze PostgreSQL schemas for performance bottlenecks and propose indexing, caching, and migration optimizations.

Updated Mar 29, 2026
One-click install
npx skills add https://github.com/sigitpoerwo/repoworkspace_zahra --skill database-operations-sigitpoerwo
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: database-operations
Source: https://github.com/sigitpoerwo/repoworkspace_zahra/tree/main/skills/01-SIAP-PAKAI/coding/database-operations
Command: npx skills add https://github.com/sigitpoerwo/repoworkspace_zahra --skill database-operations-sigitpoerwo

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This Skill helps database teams design scalable, maintainable PostgreSQL schemas, optimize queries, and manage migrations with rollback safety, reducing production incidents and performance confusion.

Core Features & Use Cases

  • Schema Design: best-practice patterns for PostgreSQL tables, relationships, and data integrity.
  • Migration & EF Core: zero-downtime migration strategies, reversible changes, and code-first workflows with EF Core.
  • Performance & Caching: indexing strategies, EXPLAIN ANALYZE driven optimizations, and Redis materialized views.

Quick Start

Analyze your PostgreSQL schema and implement the recommended indexing, migration, and caching strategies.

Frequently Asked Questions about database-operations

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

FAQPage Schema
How do I optimize slow PostgreSQL queries using EXPLAIN ANALYZE?

To optimize slow PostgreSQL queries, use EXPLAIN ANALYZE to identify performance bottlenecks in your schema. This Skill proposes targeted optimization steps, including indexing strategies and partial indexes, to resolve execution plan inefficiencies and improve query speed.

What are partial indexes and when do I need them in PostgreSQL?

Partial indexes in PostgreSQL index only a subset of rows matching a conditional predicate. You need them to optimize query performance for specific access patterns while reducing storage overhead compared to full-table indexes.

How to run zero-downtime database migrations with EF Core?

Running zero-downtime database migrations with EF Core involves applying reversible migration strategies across development, staging, and production. This Skill provides guardrails for data integrity and rollback to ensure safe schema changes without disrupting active users.

Can I use Redis materialized views for caching PostgreSQL query results?

Yes, you can use Redis materialized views for caching PostgreSQL query results. This approach offloads read traffic by storing pre-computed query outputs, significantly reducing database load and accelerating response times for frequent access patterns.

What is the best way to design a scalable PostgreSQL schema?

The best way to design a scalable PostgreSQL schema involves applying best-practice patterns for tables, relationships, and data integrity. This Skill helps structure schemas with partitioning and indexing strategies to ensure maintainability and high performance.