postgresql

Design PostgreSQL schemas with data types, indexing, constraints, and RLS policies.

2|Updated Feb 6, 2026
One-click install
npx skills add https://github.com/bcastelino/agent-skills-kit --skill postgresql-bcastelino
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: postgresql
Source: https://github.com/bcastelino/agent-skills-kit/tree/main/skills/postgresql
Command: npx skills add https://github.com/bcastelino/agent-skills-kit --skill postgresql-bcastelino

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

This Skill helps you design robust, efficient, and scalable PostgreSQL database schemas by providing best practices, data type recommendations, and advanced feature guidance.

Core Features & Use Cases

  • Schema Design: Create optimal table structures, choose appropriate data types, and define constraints.
  • Performance Tuning: Implement effective indexing, partitioning, and Row-Level Security (RLS) strategies.
  • Use Case: When designing a new e-commerce backend, use this Skill to define tables for users, products, and orders, ensuring proper indexing and data integrity for high performance.

Quick Start

Use the postgresql skill to design a schema for a blog application including tables for posts, users, and comments.

Frequently Asked Questions about postgresql

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

FAQPage Schema
How do I design a PostgreSQL schema for high performance and scale?

PostgreSQL schema design for scale requires appropriate data type selection like TIMESTAMPTZ and BIGINT, strict normalization principles, and strategic indexing to ensure query performance and data integrity.

What are the best practices for choosing PostgreSQL data types?

PostgreSQL data type selection best practices involve matching types to data characteristics, using NUMERIC for precise decimals, TIMESTAMPTZ for timestamps, and BIGINT for large identifiers to maintain accuracy and optimize storage.

How do I plan indexing and partitioning strategies for a PostgreSQL database?

PostgreSQL indexing and partitioning strategies involve implementing targeted indexes for frequent queries and partitioning large tables, applying performance patterns to maintain query speed as data volume grows.

Can I use Row-Level Security policies to control data access in PostgreSQL?

Row-Level Security policies in PostgreSQL allow you to define access patterns directly in the schema, ensuring users only see rows permitted by the defined constraints without requiring application-level filtering.

When should I review my PostgreSQL tables for optimization and maintainability?

Review PostgreSQL tables for optimization when designing new features or experiencing performance degradation, checking normalization adherence, constraints, and indexing to ensure the schema maintains scale and maintainability.