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 agentmods add skills/phuryn/pm-skills/sql-queriesnpx skills add phuryn/pm-skills --skill sql-queriesgit clone --depth 1 https://github.com/phuryn/pm-skillsWrote 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/phuryn/pm-skills/sql-queries)<a href="https://agentmods.dev/skills/phuryn/pm-skills/sql-queries"><img src="https://agentmods.dev/badge/skills/phuryn/pm-skills/sql-queries.svg" alt="Measured on agentmods" height="20"></a>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 | $0.00055 | $0.00784 |
| Opus 5 | $0.00028 | $0.00392 |
| Sonnet 5 | $0.00011 | $0.00157 |
| Haiku 4.5 | $0.00006 | $0.00078 |
Grade A, and why
sql-queries 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 4d 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.
Copies of this mod
1 near-identical copy found in the catalogue:
- sql-queries — 100% identical, 0 lines differ
How it starts
The opening of the file, as written. The whole thing — 88 lines — stays where its author put it; the contents beside it link to each section on GitHub.
SQL Query Generator
Purpose
Transform natural language requirements into optimized SQL queries across multiple database platforms. This skill helps product managers, analysts, and engineers generate accurate queries without manual syntax work.
How It Works
Step 1: Understand Your Database Schema
- If you provide a schema file (SQL, documentation, or diagram description), I will read and analyze it
- Extract table names, column definitions, data types, and relationships
- Identify primary keys, foreign keys, and indexing strategies
Step 2: Process Your Request
- Clarify the exact data you need to retrieve or analyze
- Confirm the SQL dialect (BigQuery, PostgreSQL, MySQL, Snowflake, etc.)
- Ask for any additional requirements (filters, aggregations, sorting)
Step 3: Generate Optimized Query
- Write efficient SQL that leverages your database structure
- Include comments explaining complex logic
- Add performance considerations for large datasets
- Provide alternative approaches if applicable
Step 4: Explain and Test
- Explain the query logic in plain English
- Suggest how to test or validate results
- Offer tips for performance optimization
- If you want, generate a test script or sample data
Usage Examples
Example 1: Query from Schema File
Upload your database_schema.sql file and say:
"Generate a query to find users who signed up in the last 30 days
and had at least 5 active sessions"
Example 2: Query from Diagram Description
"Here's my database: Users table (id, email, created_at), Sessions table
(id, user_id, timestamp, duration). Generate a query for average session
duration per user in January 2026."
Example 3: Complex Analysis Query
"Create a BigQuery query to analyze our revenue by region and customer tier,
including year-over-year growth rates."
Key Capabilities
- Multi-Dialect Support: Works with BigQuery, PostgreSQL, MySQL, Snowflake, SQL Server
- File Reading: Reads schema files, SQL dumps, and data documentation
- Query Optimization: Suggests indexes, partitioning, and performance improvements
- Explanation: Breaks down queries for learning and documentation
- Testing: Can generate test queries and sample data scripts
- Script Execution: Create executable SQL scripts for your database
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.
- 4d ago First seen · 88 lines · 55 tokens per session scan A 18da062d5171
sql-queries is a skill published in the GitHub repository phuryn/pm-skills (25,964 stars, last pushed 2mo ago), licensed MIT. It adds 55 tokens to every session and 784 once invoked, about $0.0003 per session on Opus 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
sql-generation
Use this skill when the user asks to "write a SQL query", "help me query this data", "how do I get this metric from the database", "generate SQL for", "query for retention", "SQL to find churned users", "write a query for my analytics", or needs SQL to answer a specific product analytics question. This skill generates…
pmm-resume
Resume reviewer and tailoring engine for Product Marketing Managers (IC to VP, including AI PMM roles). Takes baseline resume + job description → dissects JD → ranks bullets by impact fit → rebuilds complete resume in one pass. Trigger on: resume + JD paste, "tailor this", "which bullets for this role", "rebuild for…
prd
Guides Product Managers and Product Marketing Managers to co-create complete Product Requirements Documents with embedded Solution Stories. Reads brain context (positioning, ICP, Revenue Levers) to anchor PRDs in strategy. Outputs: structured Solution Story for GTM communications + full PRD for execution alignment.
beachhead-segment
Identifies and scores your highest-priority beachhead segment using four-dimension scoring (Burning Pain, Willingness to Pay, Winnability, Referral Potential) with blocking gates. Reads brain context (ICP, positioning, competitive landscape, proof points) and, when available, guardrails from prior beachhead decisions…
workflow-orchestrator
Orchestrates multi-skill PMM programs end-to-end — chains positioning, competitive, GTM strategy, campaign briefs, stakeholder maps, and retros into one coherent program with a master document and brain updates. Trigger on: "run full GTM workflow", "run a full launch", "launch [product] end to end", "positioning…
positioning-messaging
Builds or audits positioning statements, messaging hierarchies, homepage copy, and persona cards using April Dunford's Obviously Awesome framework across five modes (build, audit, fletch, sales-enablement, homepage). Refuses to generate without a named primary persona and 3+ alternatives including status quo, and…