Skip to content
Back to skills

Database Schema

ASecurity

Design a database schema

  • 57 stars
  • 0 votes
  • 0 copies
  • 1 view
  • Added October 17, 2026
databasesgosqldatabase

Security analysis

A100/100

Scanned October 17, 2026

npx -y skills add diegosouzapw/awesome-omni-skill --skill database-schema --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Database Schema?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Database Schema
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/diegosouzapw-database-schema/badge)](https://www.skillsdirectory.com/skills/diegosouzapw-database-schema)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: database-schema
description: Design a database schema
---

# Database Schema Design

Help me design a database schema:

## Requirements

1. **What are we storing?** Describe the data.
2. **Relationships**: How do entities relate?
3. **Access patterns**: How will data be queried?
4. **Scale**: Expected data volume?
5. **Database**: PostgreSQL, MySQL, MongoDB, etc.?

## Entity Design

For each entity, define:

### Table Structure

- Table name (plural, snake_case)
- Columns with types
- Primary key
- Timestamps (created_at, updated_at)
- Soft delete (deleted_at) if needed

### Constraints

- NOT NULL where required
- UNIQUE constraints
- CHECK constraints for validation
- DEFAULT values

### Relationships

- Foreign keys
- ON DELETE behavior
- Junction tables for many-to-many

### Indexes

- Primary key index
- Foreign key indexes
- Query-specific indexes
- Composite indexes where needed

## Schema Generation

Generate:

1. CREATE TABLE statements
2. Index creation
3. RLS policies (if using Supabase)
4. Sample seed data

## Optimization Review

Check for:

- Normalization level appropriate
- Index strategy sound
- Query patterns supported
- Future scaling considerations

Generate the complete schema with comments explaining decisions.

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.