home/categories/sql-databases/langchain-ai-deepagents-examples-text-to-sql-agent-skills-query-writing-skill-md
sql-databasesdatabases

query-writing

Writes and executes SQL queries from simple SELECTs to complex multi-table JOINs, aggregations, and subqueries. Use when the user asks to query a database, write SQL, run a SELECT statement, retrieve data, filter records, or generate reports from database tables.

langchain-ai
maintainer
langchain-ai
Updated 3/17/2026
Stars
20273
Forks
2814
quick start

Installation and usage

Writes and executes SQL queries from simple SELECTs to complex multi-table JOINs, aggregations, and subqueries. Use when the user asks to query a database, write SQL, run a SELECT statement, retrieve data, filter records, or generate reports from database tables.

Installation
$ install --globalskills.sh
Usage

Once installed, you can use this skill by running the following command in your terminal:

skills use query-writing