database-fundamentals

Analyze database schema design, SQL queries, and ORM usage for correctness.

274|18|Updated Dec 23, 2025
One-click install
npx skills add https://github.com/DanielPodolsky/ownyourcode --skill database-fundamentals
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: database-fundamentals
Source: https://github.com/DanielPodolsky/ownyourcode/tree/main/.claude/skills/fundamentals/database
Command: npx skills add https://github.com/DanielPodolsky/ownyourcode --skill database-fundamentals

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This Skill analyzes and guides reviews of database schema design, SQL queries, and ORM patterns to ensure correctness, consistency, and maintainability for junior developers.

Core Features & Use Cases

  • Schema review and normalization guidance to ensure data integrity and avoid redundancy.
  • Indexing strategies and query optimization checks, including migration-safe practices.
  • ORM pattern evaluation across Prisma, MongoDB, PostgreSQL, and other frameworks; enforces data integrity and proper data access patterns.
  • Use Case: When designing a new users table, perform a formal review to verify primary keys, foreign keys, appropriate data types, indexing, and migration plans.

Quick Start

Activate this skill during database schema design, migrations, and ORM modeling. AI, review the provided database schema and migrations for normalization, key constraints, and indexing, and suggest concrete improvements.

Frequently Asked Questions about database-fundamentals

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

FAQPage Schema
How do I review a database schema for normalization and key constraints?

To review a database schema for normalization, analyze primary and foreign keys, enforce not null constraints, and verify appropriate data types. This structured schema review ensures data integrity and avoids redundancy.

What is the best way to optimize SQL queries and fix N+1 problems in ORMs?

Optimize SQL queries by evaluating ORM patterns to eliminate N+1 issues and applying proper indexing strategies. This query optimization ensures efficient data access patterns and safe database migrations across frameworks like Prisma and PostgreSQL.

Does this database review approach work with Prisma and MongoDB?

Yes, this ORM pattern evaluation works with Prisma, MongoDB, and PostgreSQL. It evaluates data access layers to enforce data integrity and proper query practices across multiple database frameworks.

When do I need to check indexing strategies for database migrations?

You need to check indexing strategies during database migrations to ensure migration-safe practices and efficient query patterns. This prevents performance degradation when modifying schema design and adding key constraints.

Why does my ORM data access pattern cause data integrity issues?

ORM data access patterns cause integrity issues when schema design lacks proper primary and foreign key constraints. Evaluating ORM patterns and enforcing not null constraints resolves these inconsistencies and ensures correct data modeling.