postgresql
Skill by sickn33
Guides schema design for PostgreSQL, covering data types, constraints, indexing, partitioning and row-level security. Aimed at developers who design or review PostgreSQL tables.
Install postgresql
Built from the published package, never by AI.
git clone --depth 1 https://github.com/sickn33/agentic-awesome-skills /tmp/agentic-awesome-skills && mkdir -p ~/.claude/skills && cp -r /tmp/agentic-awesome-skills/skills/postgresql ~/.claude/skills/postgresqlRun in your terminal. Claude Code loads skills from ~/.claude/skills automatically.
git clone --depth 1 https://github.com/sickn33/agentic-awesome-skills /tmp/agentic-awesome-skills && mkdir -p ~/.gemini/antigravity-cli/skills && cp -r /tmp/agentic-awesome-skills/skills/postgresql ~/.gemini/antigravity-cli/skills/postgresqlAntigravity CLI loads skills from ~/.gemini/antigravity-cli/skills, or .agents/skills for one project.
Skills can run scripts on your machine. Some need an API key: check the README.
About
PostgreSQL Table Design is an agent skill that guides an assistant through designing a PostgreSQL schema. It sets out steps to capture entities, access patterns and scale targets, then choose data types and constraints, add indexes checked with EXPLAIN, and plan partitioning or row-level security. It also lists core rules, PostgreSQL gotchas and data types to avoid, such as timestamp without time zone, char(n), varchar(n), money and serial.
The skill covers B-tree, GIN, GiST and BRIN indexes, declarative partitioning by range, list and hash, and table types including regular, temporary and unlogged. It is meant for developers and reviewers working on PostgreSQL tables. The skill says it should not be used for non-PostgreSQL databases or for query tuning without schema changes. Its safety section advises backups, a rollback plan and staging validation before destructive DDL.
Written from the project's SKILL.md and checked against it.
What it can do
- Data type selectionGuidance on choosing PostgreSQL data types and avoiding discouraged ones.
- ConstraintsRules for NOT NULL, foreign keys, UNIQUE, CHECK and EXCLUDE constraints.
- IndexingAdvice on B-tree, composite, covering, partial, expression, GIN, GiST and BRIN indexes.
- PartitioningGuidance on range, list and hash partitioning and when to use each.
- Row-level securitySteps to enable RLS policies and test them as non-owner roles.
- Table typesExplains regular, temporary and unlogged tables and their trade-offs.
What you need
- PostgreSQL database
- PostgreSQL 15 or later for NULLS NOT DISTINCT
- PostgreSQL 18 or later for uuidv7()
- pgvector extension for vector types
Try asking
- Design a PostgreSQL schema for an orders and customers system
- Which PostgreSQL data types should I use for money and timestamps?
- Suggest indexes for a PostgreSQL table filtered by status and user_id
Good to know
- Only for PostgreSQL. Not for non-PostgreSQL databases.
- The current_user_id() function in the RLS example is a placeholder, not built in.
- The Update-Heavy Tables section is empty in the source.
- The file header marks the skill as risk: critical.
Security check
ANo download-and-run commands, hidden instructions or signs of sending keys out were found.
Checked automatically: skills/postgresql/SKILL.md. This looks for known risky patterns and is not a full audit. How grades work
Inside the skill
-
SKILL.md18 KB
Alternatives to postgresql
All alternatives →Creates, configures and manages datasets on the Hugging Face Hub, including SQL-based querying and transformation. Built for people who edit dataset content and metadata directly, alongside the HF MCP server.
Diagnoses and repairs gbrain's Postgres access when a command or MCP result shows a GBRAIN_DB_ACCESS marker, or when the operator reports the brain database is down. It runs the hardcoded gbrain db-repair ladder and verifies the result with a re-probe.
Manages clusters, instances, and backups for AlloyDB for PostgreSQL. Built for creating, configuring, and administering AlloyDB databases, not general PostgreSQL or Cloud SQL instances.
Writes, reviews and migrates Supabase logs queries against the ClickHouse logs table served by the logs.all.otel endpoint. Built for developers who write Logs Explorer SQL or convert older BigQuery logs queries.
Diagnoses and fixes slow Paperclip PostgreSQL queries using Cloud and Neon evidence, local benchmarks, regression tests, and a pull request with passing checks. Built for engineers working on Paperclip.
Guides AI assistants through Prisma 8 projects built on @prisma/orm-postgres, @prisma/orm-sqlite, or @prisma/orm-mongo. It covers data contracts, migrations, typed queries and runtime setup for developers on Prisma 8.
Compare with hugging-face-datasets, db-repair or alloydb-basics
postgresql: common questions
What does the PostgreSQL skill help with?
It helps design PostgreSQL schemas, covering data types, constraints, indexes, partitioning and row-level security. It also includes core rules and gotchas for PostgreSQL.
Which data types does the skill say to avoid?
It says not to use timestamp without time zone, char(n), varchar(n), money, timetz, timestamptz with a precision, and serial. It recommends timestamptz, text, numeric and generated always as identity instead.
Is this skill only for PostgreSQL?
Yes. The source says it should not be used when targeting a non-PostgreSQL database or when a DB-agnostic modeling guide is needed.
How do I install postgresql?
Run the command above to copy the skill into ~/.claude/skills/. Claude Code picks it up automatically.
Is postgresql free?
The code is published under the MIT licence. The service it connects to may have its own pricing.
Is postgresql safe to use?
It scores 89 of 100. Grades: maintenance A, licence A, quality A. Security check: grade A, no risky patterns found in the files checked. Review the code before you install. How grades work.
What are alternatives to postgresql?
Similar skills: hugging-face-datasets, db-repair, alloydb-basics, clickhouse-logs-queries.
