Skip to content
Back to skills

Database Query Helper

ASecurity

SQL query builder and optimizer. Generates queries, explains execution plans, and optimizes slow queries. Triggers: sql query, database query, sql optimization.

  • 11 stars
  • 0 votes
  • 0 copies
  • 2 views
  • Added September 10, 2026
toolssqldebuggingdatabase

Security analysis

A100/100

Pro scans all 3 files and shows the line behind each finding

Scanned September 10, 2026

npx -y skills add luokai0/ai-agent-skills-by-luo-kai --skill database-query-helper --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Database Query Helper?

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

Security grade badge for Database Query Helper
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/luokai0-database-query-helper/badge)](https://www.skillsdirectory.com/skills/luokai0-database-query-helper)

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: skylv-sql-helper
slug: skylv-sql-helper
version: 1.0.0
description: "SQL query builder and optimizer. Generates queries, explains execution plans, and optimizes slow queries. Triggers: sql query, database query, sql optimization."
author: SKY-lv
license: MIT
tags: [automation, tools]
keywords: [automation, tools]
triggers: sql-helper
---

# SQL Helper

## Overview
Helps write, optimize, and debug SQL queries.

## When to Use
- User asks to "write a SQL query" or "optimize this query"
- Debugging slow database operations

## Pagination
SELECT * FROM users ORDER BY id LIMIT 20 OFFSET 40;

## Join with Aggregation
SELECT u.name, COUNT(o.id) as order_count
FROM users u
LEFT JOIN orders o ON u.id = o.user_id
GROUP BY u.id;

## Optimization Rules
- Add indexes on WHERE/JOIN columns
- Avoid SELECT * - specify columns
- Use EXPLAIN to analyze execution plan
- Optimize JOIN order (small table first)
- Add LIMIT for pagination

## Anti-Patterns to Avoid
- SELECT * in production code
- Nested subqueries (use JOINs or CTEs)
- OR in WHERE clause (use IN or UNION)

Files in this skill

  • .clawhub/origin.json153 B
  • SKILL.md1.1 KB
  • _meta.json140 B

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.