Database schema design for PostgreSQL/MySQL with normalization, relationships, constraints. Use for new databases, schema reviews, migrations, or encountering missing PKs/FKs, wrong data types, premature denormalization, EAV anti-pattern.
Install with Tessl CLI
npx tessl i github:secondsky/claude-skills --skill database-schema-design93
Does it follow best practices?
Agent success when using this skill
Validation for skill structure
Primary keys, foreign keys, indexes, and audit columns
UUID primary keys
0%
100%
All tables have PKs
100%
100%
Foreign keys explicit
100%
100%
ON DELETE/UPDATE specified
100%
100%
FK indexes present
100%
100%
Audit columns all tables
50%
100%
TIMESTAMPTZ for timestamps
100%
100%
NOT NULL on required fields
100%
100%
Bounded VARCHAR lengths
100%
100%
DECIMAL for money
100%
100%
CHECK for enum status
100%
100%
CHECK for numeric ranges
100%
100%
Without context: $0.1652 · 34s · 8 turns · 9 in / 2,358 out tokens
With context: $0.3738 · 59s · 16 turns · 15 in / 3,471 out tokens
Normalization, EAV avoidance, naming conventions, soft deletes
No EAV pattern
100%
100%
JSONB for metadata
100%
70%
GIN index on JSONB
100%
100%
Soft delete pattern
100%
100%
Junction table for M:M
100%
100%
Table naming convention
100%
100%
FK column naming
100%
100%
Index naming convention
100%
100%
Normalized 3NF
100%
100%
NOT NULL required fields
100%
100%
Bounded VARCHAR
100%
100%
TIMESTAMPTZ audit columns
75%
75%
No polymorphic comments
100%
100%
Without context: $0.1940 · 50s · 7 turns · 8 in / 3,613 out tokens
With context: $0.4200 · 1m 9s · 15 turns · 3,669 in / 3,982 out tokens
Cascade rules, updated_at triggers, BOOLEAN types, data types
CASCADE on org delete
100%
100%
CASCADE on project delete
100%
100%
SET NULL on user delete
100%
100%
updated_at trigger function
100%
100%
Trigger on each table
100%
100%
BOOLEAN for flags
100%
100%
CHECK on status enum
70%
100%
CHECK on priority range
100%
100%
UUID primary keys
0%
100%
FK indexes present
100%
100%
TIMESTAMPTZ audit columns
100%
100%
NOT NULL on required fields
100%
100%
Without context: $0.1454 · 32s · 7 turns · 8 in / 2,096 out tokens
With context: $0.4458 · 1m 12s · 19 turns · 18 in / 4,113 out tokens
Table of Contents
If you maintain this skill, you can claim it as your own. Once claimed, you can manage eval scenarios, bundle related skills, attach documentation or rules, and ensure cross-agent compatibility.