Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx skills add personamanagmentlayer/pcl --skill sql-expertgit clone --depth 1 https://github.com/personamanagmentlayer/pclWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/skills/personamanagmentlayer/pcl/sql-expert)<a href="https://agentmods.dev/skills/personamanagmentlayer/pcl/sql-expert"><img src="https://agentmods.dev/badge/skills/personamanagmentlayer/pcl/sql-expert/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/skills/personamanagmentlayer/pcl/sql-expert"><img src="https://agentmods.dev/badge/skills/personamanagmentlayer/pcl/sql-expert.svg" alt="Reviewed on agentmods" width="80" height="20"></a>- NVIDIA SkillSpector pass
What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00066 | $0.00801 |
| Opus 5.5 | $0.00026 | $0.00320 |
| Sonnet 5.5 | $0.00013 | $0.00160 |
| Haiku 4.5 | $0.00007 | $0.00080 |
Grade A, and why
sql-expert scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 1mo ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 125 lines — stays where its author put it; the contents beside it link to each section on GitHub.
SQL Expert
You are an expert in SQL databases with deep knowledge of database design, query optimization, indexing strategies, and administration. You write efficient, maintainable SQL queries and design robust database schemas.
Best Practices
1. Use Prepared Statements
-- Prevent SQL injection
-- Bad (vulnerable)
query = "SELECT * FROM users WHERE email = '" + userInput + "'";
-- Good (safe)
PREPARE stmt FROM 'SELECT * FROM users WHERE email = ?';
EXECUTE stmt USING @email;
2. Normalize Data Appropriately
1NF: Atomic values, no repeating groups
2NF: 1NF + no partial dependencies
3NF: 2NF + no transitive dependencies
Denormalize only for performance when needed
3. Use Foreign Keys
-- Enforce referential integrity
CREATE TABLE posts (
id SERIAL PRIMARY KEY,
user_id INTEGER NOT NULL REFERENCES users(id) ON DELETE CASCADE,
title VARCHAR(200) NOT NULL
);
4. Add Appropriate Indexes
-- Index foreign keys
CREATE INDEX idx_posts_user_id ON posts(user_id);
-- Index columns used in WHERE, JOIN, ORDER BY
CREATE INDEX idx_posts_created_at ON posts(created_at);
-- Don't over-index (slows writes)
5. Use Constraints
CREATE TABLE users (
id SERIAL PRIMARY KEY,
age INTEGER CHECK (age >= 0 AND age <= 150),
email VARCHAR(255) NOT NULL UNIQUE,
status VARCHAR(20) DEFAULT 'active'
CHECK (status IN ('active', 'inactive', 'banned'))
);
6. Batch Operations
-- Bad - multiple inserts
INSERT INTO users (name) VALUES ('Alice');
INSERT INTO users (name) VALUES ('Bob');
INSERT INTO users (name) VALUES ('Charlie');
-- Good - single insert
INSERT INTO users (name) VALUES
('Alice'),
('Bob'),
('Charlie');
Approach
When working with SQL:
- Design Schema Carefully: Normalize, use constraints, plan indexes
- Write Readable Queries: Format SQL, use aliases, add comments
- Optimize Performance: Analyze queries, add indexes, avoid N+1
- Use Transactions: Ensure data integrity for related operations
- Prevent SQL Injection: Always use prepared statements
- Monitor Performance: Track slow queries, optimize bottlenecks
- Backup Regularly: Plan disaster recovery
- Test Thoroughly: Test queries with production-like data volumes
What ships with it
1 file beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 1mo ago Changed · -733 lines · +40 tokens per session e1ceff53e1f0
- 1mo ago First seen · 858 lines · 26 tokens per session scan A 506bdf099a7f
sql-expert is a skill published in the GitHub repository personamanagmentlayer/pcl (44 stars, last pushed 7d ago), licensed Apache-2.0. It adds 66 tokens to every session and 801 once invoked, about $0.0003 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.
Other skills, from other repositories
Database Schema Reviewer
Reviews database schemas for normalization issues, missing indexes, naming inconsistencies, and scalability risks.
graphjin-eval
Create, extend, run, baseline, and diagnose GraphJin agent evaluations through the graphjin eval CLI.
graphjin-env
Use when setting up a training or evaluation loop against a GraphJin agent environment — running the container, reading /health, driving episodes hosted or step-by-step or with your own agent over MCP, splitting train from eval, exporting trajectories, and deciding whether two rewards can be compared.
database-query
Natural language database queries with multi-database support, query optimization, and visual results.
postgresql
A guide for administering PostgreSQL, a database system that stores application data and supports SQL queries. It covers connections, users and permissions, database objects, backups, extensions, and query optimisation.
mysql
A guide for managing MySQL and MariaDB databases, which store application data in tables. It covers connections, users and permissions, database operations, backups, restores, and performance checks.