$npx skillfedfor your agent

database-fundamentals

Database Fundamentals guides code review of schemas, queries, and migrations across SQL and NoSQL systems. It surfaces common pitfalls like N+1 queries, missing indexes, and unsafe string concatenation, while providing checklists for normalization, data types, and reversible migrations.

Database Fundamentals reviews schema design, queries, and migrations to catch normalization issues, missing indexes, and N+1 problems.

AI-generated summary based on this skill's SKILL.md

★ 265  17 MITupdated by DanielPodolsky

Decision gist · record as of 2026-06-27

Database Fundamentals reviews schema design, queries, and migrations to catch normalization issues, missing indexes, and N+1 problems. Database Fundamentals guides code review of schemas, queries, and migrations across SQL and NoSQL systems. It surfaces common pitfalls like N+1 queries, missing indexes, and unsafe string concatenation, while providing checklists for normalization, data types, and reversible migrations.

manual: git clone https://github.com/DanielPodolsky/ownyourcode → cp -r ownyourcode/.claude/skills/fundamentals/database ~/.claude/skills/database
.claude/skills/fundamentals/database/SKILL.md · version cc5d9fc3

Use it when

  • Database Fundamentals identifies N+1 query problems by analyzing how your code fetches related data.
  • Database Fundamentals teaches SQL injection prevention by enforcing parameterized queries—separating SQL code from user input so attackers.

Verify before relying

Read SKILL.md below before installing (1 file). Open directory: indexed for reading, not audited.

Same gist for agents: .md · .json

Install

DanielPodolsky/ownyourcode/database · repository language: Shell

Open directory. Skills are indexed for reading, not audited. Review a skill's body before installing it.

Frequently asked questions

AI-generated answers based on this skill's SKILL.md and metadata

What does database-fundamentals cover in schema review?

Database Fundamentals guides you through schema design review by checking normalization, primary and foreign keys, and data types. It helps ensure your tables follow proper structure, relationships are correctly defined, and columns use appropriate types for their data. This foundation prevents future scaling issues and data integrity problems.

How can I avoid N+1 queries in my application?

Database Fundamentals identifies N+1 query problems by analyzing how your code fetches related data. Common solutions include eager loading (fetching all related records upfront), batch queries, or restructuring your ORM calls. The skill helps you spot where loops trigger repeated queries and recommends fixes for Prisma, MongoDB, and other ORMs.

What is SQL injection prevention with parameterized queries?

Database Fundamentals teaches SQL injection prevention by enforcing parameterized queries—separating SQL code from user input so attackers cannot manipulate your statements. It flags unsafe string concatenation and shows how to use placeholders and bound parameters. This is critical for any application accepting user data.

What database indexing strategy should I use for my queries?

Database Fundamentals evaluates your index strategy by analyzing query patterns and recommending where indexes help most. It covers single-column indexes, composite indexes for multi-column queries, and when indexing hurts write performance. Proper indexing dramatically improves SELECT speed without changing your code.

How do I ensure database migrations are reversible and safe?

Database Fundamentals checks that your migrations are reversible and prevent data loss. It verifies up/down steps are paired, destructive changes are avoided or backed up, and rollback paths exist. Safe migrations let you deploy confidently and recover quickly if issues arise in production.

What are common database anti-patterns and mistakes to avoid?

Database Fundamentals surfaces anti-patterns like SELECT *, missing foreign keys, denormalization without justification, and pagination without indexes on large datasets. It provides a junior developer guide to schema design, helping you recognize pitfalls early and follow best practices for normalization, eager/lazy loading, and EXPLAIN analysis.

SKILL.md

Rendered from the published skill. Quoted content, verbatim.

Database Fundamentals Review

> "Your database is the foundation. Build it wrong, and everything above it will crack."

When to Apply

Activate this skill when reviewing: - Schema design and migrations - SQL/NoSQL queries - ORM model definitions - Data relationships - Index creation - Query performance


Review Checklist

Schema Design
  • [ ] Normalization: Is data normalized appropriately (no excessive duplication)?
  • [ ] Denormalization justified: If denormalized, is there a performance reason?
  • [ ] Primary keys: Does every table have a clear primary key?
  • [ ] Foreign keys: Are relationships enforced at the database level?
  • [ ] Data types: Are appropriate types used (not everything TEXT)?
Indexes
  • [ ] Query-based: Are indexes created for frequently queried columns?
  • [ ] Composite indexes: Are multi-column queries covered?
  • [ ] Not over-indexed: Are there unnecessary indexes

(truncated - see the full file via the links below)

File tree — 1 file
.claude/skills/fundamentals/database/SKILL.md

Let your AI agent find skills like this

Example. Real query, live index.

You found this page by searching. An agent finds it by wishing: SkillFed indexes 56,283 agent skills by what they can do, searchable in plain language.

wish › “Review schema design for normalization, primary/foreign keys, and data types”

Give your agent the search over MCP, or paste the wish link into any chat. No install? Search from any chat →

Related skills

database-design
by CloudAI-X · CloudAI-X/claude-workflow-v2

Database Design guides you through schema normalization, indexing strategies, and query optimization for both SQL and NoSQL systems. It covers normalization forms, denormalization trade-offs, index types, and migration patterns to help you build performant, maintainable databases. Use it when designing tables, fixing performance issues, or planning data migrations.

MITupdated Jul 2026
★ 1,386repo stars
database-schema-design
by Pixel-Process-UG · Pixel-Process-UG/superkit-agents

This skill guides you through the complete lifecycle of database schema design, from conceptual modeling and logical design through physical optimization and safe migrations. It covers normalization principles, relationship patterns, indexing strategies, and query optimization techniques, with decision tables for choosing between SQL, document, and key-value storage engines. Includes zero-downtime migration patterns and backfill strategies to evolve schemas safely in production.

MITupdated Mar 2026
★ 1repo stars
datamodellm
by nimbalyst · nimbalyst/nimbalyst

DataModelLM is a visual editor for building database schemas in Prisma format, rendering them as entity-relationship diagrams on an interactive canvas. Define models, relationships, and constraints through a structured schema file, then view the resulting data structure graphically. Supports one-to-many, one-to-one, and many-to-many relationships with full Prisma type and attribute support.

MITupdated Jul 2026
★ 1,333repo stars
oma-db
by first-fluke · first-fluke/oh-my-agent

oma-db guides you through relational, document, and vector data modeling with schema documentation, integrity rules, and transaction design. It covers normalization, indexing, capacity planning, backup strategy, and anti-pattern remediation, plus ISO 27001/27002-aligned recommendations for security and continuity.

MITupdated Jul 2026
★ 1,195repo stars
drizzle-migrations
by curiositech · curiositech/some_claude_skills

This skill guides you through Drizzle ORM's migration workflow for SQLite databases, covering schema definition, column types, and common changes like adding tables or indexes. Learn production-ready strategies for generating migrations, applying them in code, and managing relations between tables.

MITfor claude-codeupdated Jul 2026
★ 164repo stars
database-design
by srstomp · srstomp/pokayokay

Build well-structured database schemas from requirements through deployment. This skill guides you through normalization, relationship design, index optimization, and reversible migrations—covering relational databases like PostgreSQL and MySQL, document stores like MongoDB, and ORMs including Prisma, Drizzle, and TypeORM.

MITupdated Jul 2026
★ 9repo stars

More skills jpa-patterns (MIT) · Data Write Query (NOASSERTION)

Tags
query-optimizationdata-integrityperformance-tuningschema-designsql-safetyorm-patternsmigration-strategyindexing-tacticsnormalization-rulescode-review