スキル一覧に戻る
Zaibunis

database-schema-design

by Zaibunis

0🍴 0📅 2026年1月16日
GitHubで見るManusで実行

SKILL.md


name: database-schema-design description: Design relational database schemas, create tables, and manage migrations for scalable applications.

Database Schema Design

Instructions

  1. Schema planning

    • Identify core entities
    • Define relationships (1–1, 1–many, many–many)
    • Normalize data where appropriate
  2. Table creation

    • Use clear, consistent naming conventions
    • Define primary and foreign keys
    • Apply proper data types and constraints
  3. Migrations

    • Create reversible migrations
    • Version-control schema changes
    • Avoid breaking changes in production

Best Practices

  • Use snake_case or camelCase consistently
  • Index frequently queried columns
  • Enforce data integrity with constraints
  • Design with scalability in mind
  • Document schema decisions

Example Structure

-- users table
CREATE TABLE users (
  id SERIAL PRIMARY KEY,
  email VARCHAR(255) UNIQUE NOT NULL,
  password_hash TEXT NOT NULL,
  created_at TIMESTAMP DEFAULT CURRENT_TIMESTAMP
);

-- posts table
CREATE TABLE posts (
  id SERIAL PRIMARY KEY,
  user_id INTEGER REFERENCES users(id),
  title VARCHAR(255) NOT NULL,
  content TEXT,
  created_at TIMESTAMP DEFAULT CURRENT_TIMESTAMP
);

スコア

総合スコア

40/100

リポジトリの品質指標に基づく評価

SKILL.md

SKILL.mdファイルが含まれている

+20
LICENSE

ライセンスが設定されている

0/10
説明文

100文字以上の説明がある

0/10
人気

GitHub Stars 100以上

0/15
最近の活動

3ヶ月以内に更新がある

0/10
フォーク

10回以上フォークされている

0/5
Issue管理

オープンIssueが50未満

+5
言語

プログラミング言語が設定されている

+5
タグ

1つ以上のタグが設定されている

0/5

レビュー

💬

レビュー機能は近日公開予定です