sqldb-cli

Design, query, and diagnose Fabric SQL databases using sqlcmd and az rest.

Updated Aug 19, 2026
One-click install
npx skills add https://github.com/paulasilvatech/Fabric-Agentic-SDLC --skill sqldb-cli-paulasilvatech
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: sqldb-cli
Source: https://github.com/paulasilvatech/Fabric-Agentic-SDLC/tree/main/.github/skills/sqldb-cli
Command: npx skills add https://github.com/paulasilvatech/Fabric-Agentic-SDLC --skill sqldb-cli-paulasilvatech

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve? Working with a SQL database in Microsoft Fabric requires juggling schema authoring, read-only querying, and performance diagnostics across T-SQL, REST APIs, and CLI tools, and mistakes like hitting the wrong endpoint or guessing workspace IDs waste time and produce wrong results. ## Core Features & Use Cases - Schema Authoring: Create tables, constraints, indexes, vector columns, and temporal tables, run DML, and deploy dacpac files via SqlPackage against a Fabric SQL database. - Read-Only Querying: Explore catalogs, run SELECT queries, perform vector similarity search, and execute temporal queries through sqlcmd with Entra ID authentication. - Performance Diagnostics: Investigate Query Store data, live and intermittent blocking, regressed plans, wait statistics, and CPU/IO pressure using DMVs and Extended Events. - Use Case: When users report intermittent slowness, run volatile query detection against Query Store, follow the wait-category decision tree, and identify whether blocking, plan regression, or resource pressure is the root cause. ## Quick Start Ask the assistant to create a table, run a query, or diagnose slow queries in your Fabric SQL database, and it will pick the right mode and execute the commands.

Frequently Asked Questions about sqldb-cli

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I create a table in a Fabric SQL database from the CLI?▼

Use the authoring mode, which discovers the existing schema first, then executes CREATE TABLE T-SQL through sqlcmd with the -Q or -i flag. Composing the DDL is not enough; the statement must actually run against the database to persist the change.

How to diagnose slow queries in SQL database in Fabric?▼

Start with volatile query detection in Query Store to find queries with high coefficient of variation, then run wait category analysis to classify the root cause as locking, CPU, IO, or memory. Follow the investigation workflows for blocking, regression, or resource pressure.

What is the difference between the SQL database endpoint and the SQL analytics endpoint?▼

The SQL database endpoint is the live OLTP engine supporting vector search, stored procedures, Query Store, and DMVs. The SQL analytics endpoint is a read-only replicated copy for cross-database queries and BI, but it lacks Query Store, DMVs, and security policy enforcement.

Does Fabric SQL database support SQL authentication?▼

No, SQL authentication is not supported. All connections must use Microsoft Entra ID, typically via sqlcmd with the -G flag or an explicit authentication method, backed by an authenticated Azure CLI session.

Why is my table missing from the SQL analytics endpoint?▼

Tables are skipped from mirroring when they exceed the 1000-table limit, use unsupported primary key types, or contain vector, json, or computed columns. Check sys.dm_change_feed_errors and query the OLTP endpoint for those objects instead.

When should I use sqldw-cli instead of sqldb-cli?▼

Use sqldw-cli for Warehouse items, Lakehouse SQL endpoints, and Mirrored Databases in Fabric. sqldb-cli is only for the SQL database item, which is the OLTP SQL Server engine; notebooks belong to spark-cli.