Skip to content
SkillModel-led712 tokens in use

sql-queries

Generate commented SQL from a natural language request for BigQuery, PostgreSQL, MySQL, Snowflake and SQL Server, with explanations and performance notes.

28,201 stars on the repository MIT Licensephuryn/pm-skills · pm-data-analytics/skills/sql-queries
claude plugin install pm-data-analytics@pm-skills
View source

Install command as written in the repository's README

Skill label

measured from its files

What installing sql-queries costs

53tokens idle
712tokens in use

Idle is what sits in context while the skill is installed. In use is its instructions, loaded when it runs. Counts are approximate, made offline with cl100k_base.

Model dependence Model-led

Script-ledMixedModel-led

Mostly instructions, so how well it works depends on the model that follows them.

This describes the skill's structure, how much of it is scripts. It does not say how well it works.

Touches

Nothing detected: no shell, network, file writes, git or credentials in its files.

Declared tags come from the skill's frontmatter; detected ones from its scripts, its code blocks and the commands it names in inline code. This is detected, not audited.

How it scores

Quality

How well the skill is written, counted from its own files: its frontmatter, its steps, examples, stated output and constraints, its size and whether every file it ships is one it names.How we score it →
Excellent
  • Frontmatter12/15
  • Structure22/25
  • Examples12/15
  • Output10/15
  • Size15/15
  • Resources10/15

Security

Starts at 100 and loses points for each thing in the skill's files that a reader should look at first.How we score it →
Excellent

No findings.

Repository health

Pre-computed score based on development activity, maintenance, community, maturity, and trend momentum.How we score it →
Good
  • Development activity80
  • Maintenance76
  • Community60
  • Maturity32
  • Momentum40

sql-queries turns a business question into a SQL query. It reads a schema file or a description of your tables, confirms the dialect and requirements, writes a commented query, explains how it works and suggests ways to test it and make it faster. A test script with sample data is available on request.

What You Get

  • A query with comments on any complex logic
  • An explanation of what the query does and how
  • Performance notes on indexes, partitioning and large datasets
  • Alternative approaches where they apply
  • Validation tips, and a test script with sample data on request

Common Use Cases

  • Finding users who signed up in the last 30 days with at least five sessions
  • Averaging session duration per user for a month
  • Building a revenue report by region and tier with year-over-year growth

What Makes It Unique

It starts from your schema. It extracts tables, columns, types, keys and relationships from a file or description and asks which dialect you use, so the query matches your own database and its naming.

Under The Hood

The skill is one SKILL.md of instructions with no bundled scripts. The agent reads any schema file, SQL dump or documentation you upload, then writes the query in the chat or in a script file. It does not connect to a database on its own. It shows example prompts and an output format.

Join founders building with open source

Opinionated takes, migration guides, cost-saving tips, and insights from the open source ecosystem.

Subscribe on SubstackJoin 750+ subscribers