AI Blocks

Putting the blocks together

This is taking longer than expected.

Try againBrowse the library
AI Blocks · All skills by job · Minds · Mini tools · How it works · From a source · Apps

AI Blocks › Track your numbers

SQL query writer

Describe what you want to know. Get a working SQL query, using joins, groups, windows and CTEs as needed.

SQL query writer is a free AI skill for the job "Track your numbers". Give the instructions to an AI assistant that supports the required files and tools, then review its output.

Free · No account · MIT licence · Made by Burhan Sebin · Level: beginner · Thinking: low

Made by Burhan Sebin. See the original on GitHub; we copied it as it is, with its licence.

What it does

A working SQL query built from a question like which customers spent the most last quarter. The skill first works out what you want measured, which things are involved and how to group or sort the result. It then maps your words to the tables and columns in your schema and finds the right join path, avoiding extra joins that inflate the numbers. It chooses the right tool: simple totals, window functions for rankings and running sums, CTEs for multi-step work, or subqueries. The SQL is formatted and commented. If a query is slow, it reads the plan and suggests indexes and restructuring.

You give it

You get

Use it when

How to use it

  1. Add it to your AI once: download it and add the folder to Claude, ChatGPT or Codex as a skill.
  2. Ask for the job in your own words. Your AI opens the skill when it fits.

More for Track your numbers

Every track your numbers skill