Repository inventory

langchain-ai/deepagents

Skills indexed from this repository, with install-style signals scoped to the repo.
4 skills34K GitHub stars0 weekly installsPythonGitHubOwner profile

Overview

This skill helps write and execute SQL queries for tasks ranging from simple single-table lookups to complex multi-table JOINs and aggregations. It guides query planning, schema inspection, safe execution, and result formatting so you can deliver precise, auditable answers from a database.

How this skill works

The skill inspects table schemas using a schema inspection tool, drafts SQL with clear aliases and constraints, and executes read-only SELECT queries with a safe default LIMIT. For complex tasks it provides a step-by-step todo plan to map joins, choose aggregates, and validate GROUP BY and WHERE logic before execution.

When to use it

  • Answer a question that requires fetching data from a database
  • Compute aggregates like totals, averages, or counts across tables
  • Combine related tables using JOINs to produce consolidated reports
  • Validate assumptions about relationships or foreign keys before analysis
  • Produce a reproducible, read-only query to share with others

Best practices

  • Identify the relevant table(s) and inspect schemas before writing SQL
  • Select only necessary columns; avoid SELECT * to reduce overhead
  • Alias tables for readability and reference join conditions explicitly
  • Apply WHERE filters before aggregation and include GROUP BY for non-aggregated columns
  • Always use a LIMIT (default 5) when previewing results and never run data-modifying statements

Example use cases

  • List top 5 customers by revenue with an Invoice -> Customer join and SUM aggregation
  • Count active users per region using GROUP BY and proper WHERE filters
  • Compare month-over-month sales by joining Orders and OrderItems and aggregating by date
  • Validate foreign-key relationships by inspecting schemas and running small JOIN queries
  • Extract a sample of rows from a table for quick schema verification

FAQ

No. It is designed for read-only queries. It never executes DML statements like INSERT, UPDATE, DELETE, or DROP.

What if multiple tables share similar column names?

Use explicit table aliases and qualify column names (alias.column) to avoid ambiguity and ensure correct JOINs.

4 skills

More from this maintainer
Other repositories and skills published under the same GitHub owner.
Skills library
Jump back to the full directory or explore grouped topics.
Built by
VeilStrat
AI signals for GTM teams
© 2026 VeilStrat. All rights reserved.All systems operational