Make the result grain explicit.
Turn your schema and a precise question into SQL you can inspect, explain and test. Keep the joins, filters and money definitions visible.
| Office | Orders | Meals | Net cents |
|---|---|---|---|
| Alder Studio | 2 | 60 | 67850 |
| Birch Software | 1 | 40 | 46000 |
| Cedar Works | 0 | 0 | 0 |
A real execution on invented data: three office rows, including the office with zero qualifying activity. SQLite only; no production data was accessed.
From a question to a reviewable query
You supply the meaning
Table names, types, keys and relationships; the SQL dialect; the question; filters; date boundaries; and the expected row grain. If the schema is in a document or a diagram description, the assistant reads that material first.
You receive an explanation
SQL with comments, a plain-English explanation and performance considerations. When requested, the assistant can also generate sample data, a test script and expected results for review.
Useful when the question is known
Works well for
- Analysts translating a defined reporting question into a query.
- Product managers learning how joins and aggregations answer a metric request.
- Engineers preparing a small test fixture before reviewing a generated report.
- Teams making date, refund and zero-activity rules explicit.
Bring more than a vague goal
- Missing relationships need clarification; the assistant cannot discover an inaccessible database.
- The package is not a database connection, a scheduler or a reporting service.
- Performance suggestions do not replace execution plans and representative measurements.
- Generated SQL needs review before use with authorized data.
Four decisions that shape the answer
- 01 · GRAIN
- One row per office, not one row per meal or order. Aggregating item lines first prevents duplicate order counts.
- 02 · WINDOW
- Normalized UTC timestamps from October 1 inclusive to November 1 exclusive. Boundary events get a defined treatment.
- 03 · MONEY
- Integer cents, minus the total refund recorded for each item line. Meal counts remain quantities ordered.
- 04 · MISSING ACTIVITY
- Keep offices with no qualifying orders. A left join and explicit zero totals preserve those rows.
A Skill-aware assistant, plus your database engine
Extract the source ZIP and load its folder using your assistant’s supported Skill mechanism, or ask a file-capable assistant to read SKILL.md and follow it. State the subject directly when the upstream instruction uses an argument placeholder. This standalone package does not include the upstream plugin marketplace or slash commands.
A capable language model is required; subscriptions or model usage charges may apply. No additional service API key or web access is required for this workflow. Executing generated SQL requires the matching database engine. The demonstration used Python’s SQLite module and an isolated in-memory database; those test artifacts are evidence, not additional installed Skill capabilities.
A bounded check, not a universal guarantee
Counts are rule checks on one saved run. No speed comparison, production integration or cross-dialect benchmark was performed.
Original instructions, visible provenance

MIT license · copyright 2026 Pawel Huryn. The original SKILL.md and license bytes are preserved at the pinned commit.
AI-generated promotional artwork. It is not a screenshot of this run or evidence of application behavior. The distributed cover is an opaque 1024 × 1024 WebP.