sql-db-fix-expert
by Roy Yuen
A safe, expert-level database troubleshooter for fixing migrations, performance issues, and schema drift.
- Repair broken database migrations and resolve schema drift issues
- Diagnose and resolve performance bottlenecks and query deadlocks
- Safely deduplicate data and fix integrity constraint violations
$8
· or 40 creditsSecure checkout via Stripe
Included in download
- Repair broken database migrations and resolve schema drift issues
- Diagnose and resolve performance bottlenecks and query deadlocks
- Ready for Claude Code
- Includes example output and usage patterns
Sample input
My Postgres migration just failed on the users table with a unique constraint error on the email field. Can you help me fix the data and finish the migration?
Sample output
ISSUE: Failed Migration (PostgreSQL) CAUSE: Unique constraint violation on 'email' column due to duplicate records. FIX:
- Identify duplicates: SELECT email, count() FROM users GROUP BY 1 HAVING count() > 1;
- Deduplicate manual script provided.
- Rerun migration. ROLLBACK: DROP INDEX CONCURRENTLY...
sql-db-fix-expert
by Roy Yuen
A safe, expert-level database troubleshooter for fixing migrations, performance issues, and schema drift.
$8
· or 40 creditsSecure checkout via Stripe
Included in download
- Repair broken database migrations and resolve schema drift issues
- Diagnose and resolve performance bottlenecks and query deadlocks
- Ready for Claude Code
- Includes example output and usage patterns
- Instant install
Sample input
My Postgres migration just failed on the users table with a unique constraint error on the email field. Can you help me fix the data and finish the migration?
Sample output
ISSUE: Failed Migration (PostgreSQL) CAUSE: Unique constraint violation on 'email' column due to duplicate records. FIX:
- Identify duplicates: SELECT email, count() FROM users GROUP BY 1 HAVING count() > 1;
- Deduplicate manual script provided.
- Rerun migration. ROLLBACK: DROP INDEX CONCURRENTLY...
About This Skill
What it does
SQL DB Fix Expert is a specialized database reliability skill designed to diagnose and repair incidents across SQLite, PostgreSQL, and MongoDB. It functions as an on-call DBA for your AI agent, moving beyond simple query generation to provide deep troubleshooting for broken migrations, deadlocks, schema drift, and data corruption.
Why use this skill
Most AI agents lack the safety guardrails required for database operations. This skill implements a strict "read-only first" diagnostic protocol and high-risk operation gating. It prevents accidental data loss by enforcing backup verification and providing explicit rollback plans before any modification is executed. It is significantly safer and more thorough than raw prompting because it follows a structured 'Evidence-Inference-Action' workflow.
Supported Engines
- PostgreSQL: Vacuuming, lock analysis, complex migrations, and query planning.
- SQLite: Recovery, file integrity, and light-weight schema adjustments.
- MongoDB: Document validation, index optimization, and aggregation repairs.
The Output
Every interaction produces a structured incident report containing identified root causes, read-only evidence, engine-specific repair scripts, and a concrete rollback strategy. Live execution only occurs after explicit user confirmation of the proposed commands.
Use Cases
- Repair broken database migrations and resolve schema drift issues
- Diagnose and resolve performance bottlenecks and query deadlocks
- Safely deduplicate data and fix integrity constraint violations
- Generate engine-specific recovery plans for corrupted indices or tables
Known Limitations
- Cannot perform physical hardware/disk repairs.
- Limited to SQLite, PostgreSQL, and MongoDB.
- Requires user-provided credentials/connection for live execution.
How to Install
mkdir -p ~/.claude/skills && curl -sL https://www.agensi.io/api/install/sql-db-fix-expert -o /tmp/sql-db-fix-expert.zip && unzip -o /tmp/sql-db-fix-expert.zip -d ~/.claude/skills && rm /tmp/sql-db-fix-expert.zipFree skills install directly. Paid skills require purchase - use the download button above after buying.
Reviews
No reviews yet - be the first to share your experience.
Only users who have downloaded or purchased this skill can leave a review.
Early access skill
Be the first to review this skill.
Only users who have downloaded or purchased this skill can leave a review.
Security Scanned
Passed automated security review
Permissions
No special permissions declared or detected
Claude Code, Cursor, Windsurf, SKILL.md-compatible agents
Frequently Asked Questions
Learn More About AI Agent Skills
More Premium Skills
Multi-Agent Orchestration Master Library
Transform Claude Code into a coordinated multi-agent system. Battle-tested tmux orchestration patterns, YAML task queues, event-driven communication, and parallel worker management for 8+ agents.
designing-hybrid-context-layers
Architects the right retrieval strategy for every query — teaching your agent when to use RAG, a knowledge graph, or a temporal index instead of defaulting to vector search for everything.
ai-automation-qa-pack
Professional QA & UAT documentation generator for AI automation agencies and complex agent deployments.
Bounty Security Pattern Master Library — 399 Vulnerability Patterns
A premium library of 399 vulnerability patterns and DeFi attack vectors for AI-driven bug hunting and security audits.