database-designer

Design relational database schemas and generate index recommendations with migration SQL.

2|Updated Apr 15, 2026
One-click install
npx skills add https://github.com/mdnaimul22/human-skills --skill database-designer-mdnaimul22
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: database-designer
Source: https://github.com/mdnaimul22/human-skills/tree/main/skills/database-designer
Command: npx skills add https://github.com/mdnaimul22/human-skills --skill database-designer-mdnaimul22

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) and assets (resource) components.

What problem does it solve?

This skill helps you turn unclear data requirements into a well-structured database by analyzing schema quality, recommending performance indexes, and generating migration plans that reduce downtime risk.

Core Features & Use Cases

  • Schema Analyzer: Checks normalization (1NF–BCNF), data types, missing constraints, naming conventions, and can generate a Mermaid ERD from SQL DDL or JSON schema.
  • Index Optimizer: Recommends missing single/composite/covering indexes based on query patterns, detects redundant/overlapping/unused indexes, and estimates selectivity and benefit.
  • Migration Generator: Produces step-by-step forward/rollback SQL for schema changes and can generate zero-downtime expand/contract style migrations.

Quick Start

  • Ask for an end-to-end schema-and-index plan by providing your JSON schema plus the query patterns you expect (frequency, selectivity, and ORDER BY needs) and request recommendations and migration SQL to move from current to target.
  • Example natural-language instruction: “Analyze my current database JSON schema and query patterns, recommend the best indexes, then generate forward and rollback SQL to migrate to this target JSON schema with zero-downtime steps.”

Frequently Asked Questions about database-designer

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

FAQPage Schema
How do I generate a zero-downtime database migration from a JSON schema?

To generate a zero-downtime database migration, provide your current and target JSON schemas to apply an expand-contract workflow, producing ordered forward and rollback SQL steps with validation queries.

Can I analyze database normalization and missing constraints using SQL DDL?

You can analyze database normalization by inputting SQL DDL or JSON schemas to check compliance from 1NF to BCNF, identify missing constraints, validate data types, and generate a Mermaid ERD.

What is the best way to recommend missing indexes based on query patterns?

The best way to recommend missing indexes is to analyze your query patterns, frequency, and selectivity to generate single, composite, or covering index suggestions while detecting redundant or overlapping indexes.

How do I create a Mermaid ERD from an existing relational database schema?

You create a Mermaid ERD by parsing the tables, columns, and constraints from your existing relational database schema input, translating the structural relationships into a visual Mermaid diagram format.

Does this database schema analyzer require specific query details for index optimization?

Yes, index optimization requires you to provide expected query patterns, including frequency, selectivity, and ORDER BY needs, to accurately estimate benefits and recommend the correct indexes.

When should I use expand-contract workflows for SQL schema evolution?

You should use expand-contract workflows for SQL schema evolution when you need safe, zero-downtime migrations, utilizing ordered migration steps with built-in rollback and validation queries to prevent service disruption.