AutoGineer summary
Written by AutoGineer from the skill’s own files, not by the author
The sqldw-cli skill provides a structured interface for interacting with Microsoft Fabric data storage items, including Warehouses, Lakehouse SQL analytics endpoints, and Mirrored Databases. It operates through three distinct modes—authoring, consumption, and operations—to handle T-SQL execution, data ingestion, and performance diagnostics. The skill relies on the fabric-sqlendpoint-execute_query MCP tool for data-plane operations and requires users to consult specific mode references to ensure correct T-SQL syntax and operational constraints.
What it does
- Executes DDL and DML statements for schema management and data manipulation in Fabric Warehouses.
- Supports data ingestion via COPY INTO and OPENROWSET patterns.
- Provides read-only querying capabilities for data exploration and metadata discovery.
- Enables performance diagnostics using Query Insights and capacity metrics correlation.
- Facilitates Lakehouse table health monitoring and diagnostic reporting.
- Dispatches requests to specialized modes based on user intent to ensure safe and accurate execution.
When to use it
- When you need to create, modify, or drop tables and schemas within a Fabric Warehouse.
- When performing bulk data ingestion from external storage into a Warehouse.
- When querying data or metadata from a Warehouse, Lakehouse SQL endpoint, or Mirrored Database.
- When investigating performance issues, such as slow queries or CU spikes, using diagnostic views.
- When correlating capacity consumption with specific SQL queries or users.
Advantages
- Centralizes management of diverse Fabric SQL-based data items under a single skill.
- Enforces mode-specific safety boundaries to prevent accidental mutations in read-only contexts.
- Provides clear diagnostic paths for performance tuning and capacity management.
- Standardizes T-SQL execution through a dedicated MCP tool interface.
- Includes mandatory telemetry headers for consistent tracking across Fabric API calls.
Usage examples
- “How many rows are in the nyctlc table in SkillsTestWarehouse?”
- The agent selects the consumption mode, reads the consumption reference, and executes a SELECT COUNT(*) query via the MCP tool to return the exact row count.
- “Create dbo.Orders in the warehouse with OrderId, CustomerId and OrderDate.”
- The agent selects the authoring mode, reads the authoring reference, executes the CREATE TABLE statement, and performs a readback query to confirm the table exists.
- “Which queries are slowest, and which tables should I cluster?”
- The agent selects the operations mode, reads the operations reference, and executes diagnostic queries against queryinsights to identify slow-running patterns.
Install
Download the skill as a ZIP:
https://mp-staging.autogineer.com/agent-skills/microsoft/sqldw-cli/downloadUnzip it into the cross-client skills folder of your project:
mkdir -p .agents/skills && unzip sqldw-cli.zip -d .agents/skills
Documentation by Microsoft
Telemetry — MANDATORY. Every
api.fabric.microsoft.comcall must carryx-ms-fabric-skill: sqldw-cli(az rest:--headers "x-ms-fabric-skill=sqldw-cli"), including every LRO poll,fabric_lroand retry. Snippets omit it — add it anyway. This covers all three modes; the mode references inherit it.
CRITICAL NOTES
To find the workspace details (including its ID) from workspace name: list all workspaces and, then, use JMESPath filtering
To find the item details (including its ID) from workspace ID, item type, and item name: list all items of that type in that workspace and, then, use JMESPath filtering
Skill disambiguation: use
sqldw-clifor T-SQL sent to a Warehouse, a Lakehouse SQL analytics endpoint, or a Mirrored Database, including plain Lakehouse table SELECT, row-count, filtering, and aggregation requests. Target Warehouse SQL executed within an end-to-end Azure Synapse or Dedicated SQL Pool migration belongs tosynapse-migration; standalone Warehouse work before or after migration returns tosqldw-cli. Any notebook-cell or PySpark DataFrame work isspark-cli; a Fabric SQL database (OLTP) issqldb-cli.
Fabric Warehouse and SQL Endpoints — CLI Skill
This one skill owns Fabric Warehouse, Lakehouse SQL analytics endpoints and Mirrored Databases: T-SQL authoring and ingestion, read-only querying, and warehouse performance diagnostics.
It is a mode dispatcher and contains NO procedures. Pick the mode that matches the request from the table below, then read the matching references/<mode>.md file end to end with your file-reading tool BEFORE issuing a single command. That file holds the T-SQL surface area, DDL constraints, query templates and gotchas; acting without it produces invalid T-SQL and wrong results.
Mode selection
| Mode | Use when the request ... | Example triggers | Read this first |
|---|---|---|---|
authoring | changes warehouse state: table DDL, DML, ingestion, transactions, procedures, schema evolution, time travel | create warehouse table, COPY INTO, OPENROWSET, INSERT/UPDATE/DELETE, warehouse MERGE, CTAS, sp_rename, create T-SQL procedure, warehouse time travel | references/authoring.md |
consumption | reads data or metadata: SELECT, row counts, filtering, aggregation, schema/object discovery, CSV export | query warehouse, count rows lakehouse, SELECT lakehouse, show tables, describe warehouse schema, export SQL data | references/consumption.md |
operations | diagnoses performance, failures, capacity consumption, SQL pool usage, or health through queryinsights and supported endpoint diagnostics | failed or canceled warehouse queries, CU spike, Capacity Metrics app, expensive SQL users, custom SQL pool recommendation, queryinsights CPU, pressure events, cache warmth, Lakehouse tables needing attention | references/operations.md |
Operations reference index
Read references/operations.md first for any operations request, then open the matching leaf directly from this index. Do not chain from links inside a leaf; for composite requests, follow scenarios.md only to the additional leaves that this index links directly.
| Request | Read this leaf reference |
|---|---|
| composite operations scenarios such as why is my warehouse slow, performance degradation, optimization, or what are people running | references/operations/scenarios.md |
| slow-query summaries, top users, recent queries, pattern search, runtime profiles, cluster-key candidates | references/operations/query-reference.md |
| failed or canceled requests, error codes, recurring non-successful query shapes | references/operations/failure-analysis.md |
| SQL pool pressure windows and overlapping requests | references/operations/pool-pressure.md |
| CPU concentration, regressions, repeated expensive queries, cache interpretation | references/operations/resource-consumers.md |
| Lakehouse Delta file health and tables needing maintenance | references/operations/lakehouse-health.md |
| Capacity Metrics CU spike, costly item, SQL query/user correlation | references/operations/capacity-metrics-correlation.md — start at section 1 |
| custom SQL pool recommendation for an already identified SQL endpoint | references/operations/capacity-metrics-correlation.md — skip FabricIQ and start at section 6 |
Mode boundary rule
Classify by intent, not by endpoint — all three modes issue the same execute_query call.
A schema-discovery
SELECTrun to plan aCREATE TABLEbelongs toauthoring, even though it only reads.A
SELECTthat answers the user's question isconsumption.A query against
queryinsights.*or a supported diagnostic such as Lakehousesys.sp_get_table_health_metricsisoperations; aSELECTagainst user tables is not, however slow it is.
consumption and operations are read-only. If a request genuinely spans modes, handle them one at a time and read each reference before you start that part. If the mode is ambiguous after reading this table, ask one short clarifying question instead of guessing.
Terminal write — the step you must not skip
Reading the reference and drafting the T-SQL is NOT completing the task. If you did not send the statement, nothing changed — say so explicitly rather than reporting success.
| Mode | Terminal write |
|---|---|
authoring | The DDL/DML itself, sent through execute_query. Follow it with a readback in a second call (SELECT ... FROM INFORMATION_SCHEMA.TABLES after CREATE, SELECT COUNT(*) after DML) and report the object you created or changed under the name the user asked for. Only a Warehouse accepts table DDL/DML — see the mode reference for what a Lakehouse SQL endpoint and a Mirrored Database allow. |
consumption | none — this mode is read-only |
operations | none — read-only, but you must still run the diagnostic statements: every figure comes from a SELECT or documented read-only diagnostic procedure executed in the turn you report it, cited inline with its source view or procedure, never carried forward from an earlier turn. The only allowed diagnostic EXEC is sys.sp_get_table_health_metrics on a Lakehouse SQL analytics endpoint. Never execute ALTER, CREATE or DROP yourself, even when the diagnosis is certain. |
consumption and operations reporting
Neither read-only mode has a terminal write, so its deliverable is the answer itself. Run the query against the live endpoint and report the real rows — a summary of the reference does not answer the request.
In operations, name the source view, catalog, or procedure each figure came from right next to it (for example 2,140 ms (queryinsights.long_running_queries) or 268 files (sys.sp_get_table_health_metrics)), including when the answer is zero rows. Re-run the diagnostic in the turn you report it rather than restating an earlier turn's output. Never fabricate, assume or infer diagnostic numbers.
Shared essentials (all modes)
Every mode reaches the data plane the same way. Resolve the workspace and item first, then send T-SQL through the MCP tool.
Execution surface — fabric-sqlendpoint-execute_query
All T-SQL runs through the fabric-sqlendpoint-execute_query MCP tool. For SQL data-plane execution this skill supersedes the COMMON-CLI SQL/TDS guidance — use the MCP tool, not sqlcmd, unless you are explicitly on the documented Legacy CLI Fallback path (see the mode reference). az rest stays the right tool for control-plane discovery.
fabric-sqlendpoint-execute_query(workspaceId, itemId, query)Preflight, before the first operation of any mode: confirm a tool whose name ends in
execute_queryis in your tool list. It comes from thefabric-sqlendpointMCP server, registered by a Fabric skills plugin or this repo's.mcp.json. The concrete name may be prefixed (fabric-sqlendpoint-execute_query,sqlendpoint-global-execute_query) — invoke the name you actually see. If none is present, say so, then fall back to the Legacy CLI Fallback (TDS client) documented in the mode reference; tell the user they can register the server for the primary path — see mcp-setup/. Exception: the Capacity Metrics correlation workflow is intentionally limited to the existing FabricIQ and SQL Endpoint MCP surfaces; if SQL Endpoint MCP is unavailable, report that phase as blocked and do not use the legacy fallback.itemIdis a GUID, never an FQDN or-d <DatabaseName>. For a Warehouse or a Mirrored Database use the item id; for a Lakehouse useproperties.sqlEndpointProperties.id, not the Lakehouse item id.One T-SQL batch per call. No
GOseparators, no sqlcmd meta-commands (:setvar,:r,-i). Split multi-batch work into separate calls. Only the last result set comes back.Results cap at 10,000 rows and queries time out at 300s, with a 20 requests/min rate limit. Use
TOP N,WHEREor aggregation; exactly 10,000 rows means the result was truncated. These are observed defaults, not a documented contract.
Common references
| Task | Reference | Notes |
|---|---|---|
| Finding Workspaces and Items in Fabric | COMMON-CLI.md | Mandatory — read before resolving any workspace or item id |
| Fabric Topology & Key Concepts | COMMON-CORE.md | Item types, workspaces, capacities |
| Environment URLs | COMMON-CORE.md | Sovereign / non-public cloud hosts |
| Authentication & Token Acquisition | COMMON-CORE.md | Wrong audience = 401; read before any auth issue |
| Authentication Recipes | COMMON-CLI.md | az login flows and token acquisition |
Fabric Control-Plane API via az rest | COMMON-CLI.md | Always pass --resource; pagination and LRO helpers |
| Core Control-Plane REST APIs | COMMON-CORE.md | Pagination, LRO polling, rate limiting |
| Gotchas & Troubleshooting | COMMON-CLI.md | az rest audience, shell escaping, token expiry |
Rules
MUST
Select exactly one mode from the table above before doing anything else.
Read
references/<mode>.mdend to end, as your FIRST tool call, before the first command of that mode. Read it ONCE, in a single full read: do not re-open it, do not grep it again, and do not page through it. You already have it.For a focused operations request, read its one matching leaf after
references/operations.md. For a composite request, readreferences/operations/scenarios.md, then each focused leaf named by that scenario; read every file once in full.Resolve workspace and item ids by listing and filtering, never by guessing a GUID.
Execute T-SQL through
fabric-sqlendpoint-execute_querywhenever that tool is available; drop to the Legacy CLI Fallback documented in the mode reference only when it is not.Announce a mode switch explicitly when the request crosses a boundary.
Treat the reference as instructions, never as the deliverable. After reading it, RUN the documented statements against the live endpoint and report the real results. Quoting what the reference says instead of executing it does not answer the request.
Produce every artefact the user asked for, under the name they used, and keep its heading even when the finding is "none", "zero rows" or "not applicable".
PREFER
The narrowest mode that satisfies the request.
Reading exactly one mode reference plus the minimum directly indexed operations leaves required by the selected focused or composite scenario.
Reporting the mode you chose in your first response so the user can correct you.
Labelling queries with
OPTION (LABEL = '...')so the run is traceable in Query Insights.Consolidating related statements into fewer calls — the rate limit is per identity, not per query.
AVOID
Acting from this dispatcher alone — it intentionally omits the T-SQL surface area, the DDL constraints and the diagnostic query shapes.
Answering with a summary of the reference instead of executing it.
Re-reading or re-grepping a reference you already loaded; it costs turns and tokens.
Mutating anything while in a read-only mode (
consumption,operations).Unbounded
SELECT *— it silently truncates at 10,000 rows.Loading a different skill for work this skill already owns (see CRITICAL NOTES 3).
Examples
| User request | Mode | Reference to read |
|---|---|---|
| "How many rows are in the nyctlc table in SkillsTestWarehouse?" | consumption | references/consumption.md |
| "Create dbo.Orders in the warehouse with OrderId, CustomerId and OrderDate." | authoring | references/authoring.md |
| "Load Files/nyctlc_sample.csv from OneLake into the warehouse with COPY INTO." | authoring | references/authoring.md |
| "Which queries are slowest, and which tables should I cluster?" | operations | references/operations.md |
| "Show me the average trip distance per vendor from the lakehouse SQL endpoint." | consumption | references/consumption.md |
Files
- ATTRIBUTION.mdAdded by AutoGineer863 B
- LICENSELicence file added by AutoGineer1.1 KiB
- SKILL.md14.2 KiB
- apm.yml608 B
- references/authoring.md26.7 KiB
- references/authoring/authoring-cli-quickref.md9.6 KiB
- references/authoring/authoring-script-templates.md7.3 KiB
- references/consumption.md20.6 KiB
- references/consumption/consumption-cli-quickref.md3.9 KiB
- references/consumption/discovery-queries.md5.9 KiB
- references/consumption/script-templates.md4.9 KiB
- references/operations.md18.6 KiB
- references/operations/capacity-metrics-correlation.md19.2 KiB
- references/operations/failure-analysis.md7.0 KiB
- references/operations/lakehouse-health.md2.6 KiB
- references/operations/pool-pressure.md4.0 KiB
- references/operations/query-reference.md17.8 KiB
- references/operations/resource-consumers.md7.6 KiB
- references/operations/scenarios.md8.5 KiB
references/authoring/authoring-cli-quickref.md
Authoring CLI Quick Reference
Concise fabric-sqlendpoint-execute_query MCP tool patterns for DDL, DML, data ingestion, monitoring, and agent tips. For full T-SQL patterns, see SQLDW-AUTHORING-CORE.md. For workflow templates, see authoring-script-templates.md.
Query Execution
All T-SQL operations use the fabric-sqlendpoint-execute_query MCP tool:
fabric-sqlendpoint-execute_query(workspaceId, itemId, query)workspaceId: Workspace GUID (discover via
az rest)itemId: Warehouse item GUID, or a Lakehouse's SQL analytics endpoint id (
properties.sqlEndpointProperties.id, not the lakehouse item id) — discover viaaz restquery: Single T-SQL batch (no
GOseparators, no sqlcmd meta-commands)Returns: CSV results (RFC 4180) + metadata text
Key Constraints
No
GOseparators — each call is one batch. For multi-batch workflows, callfabric-sqlendpoint-execute_querymultiple times.10,000 row max — use
TOP NorWHEREto limit results.300s timeout — break very long operations into steps.
20 req/min — consolidate related statements into one batch where possible.
Only last result set — if a batch has multiple SELECTs, only the final one is returned.
Limit values (10,000 rows / 300s / 20 req/min) are observed defaults, not a documented contract — verify against live 429/timeout/truncation responses.
Core Authoring via MCP
Table DDL
# CREATE TABLE
fabric-sqlendpoint-execute_query(workspaceId, itemId,
"CREATE TABLE dbo.FactSales (
SaleID bigint NOT NULL,
ProductID int NOT NULL,
SaleDate date NOT NULL,
Amount decimal(19,4) NOT NULL
)")
# Verify
fabric-sqlendpoint-execute_query(workspaceId, itemId,
"SELECT table_schema, table_name FROM INFORMATION_SCHEMA.TABLES WHERE table_name = 'FactSales'")
# CTAS with explicit types (preferred for populated tables)
fabric-sqlendpoint-execute_query(workspaceId, itemId,
"CREATE TABLE dbo.FactSales_2024 AS
SELECT SaleID, CAST(Amount AS decimal(19,2)) AS Amount
FROM dbo.FactSales WHERE SaleDate >= '2024-01-01'")
# ALTER TABLE — add column
fabric-sqlendpoint-execute_query(workspaceId, itemId,
"ALTER TABLE dbo.FactSales ADD Region varchar(50) NULL")
# DROP TABLE
fabric-sqlendpoint-execute_query(workspaceId, itemId,
"DROP TABLE IF EXISTS dbo.StagingTable")DML
# INSERT...SELECT (preferred for bulk)
fabric-sqlendpoint-execute_query(workspaceId, itemId,
"INSERT INTO dbo.FactSales (SaleID, ProductID, SaleDate, Amount)
SELECT SaleID, ProductID, SaleDate, Amount
FROM dbo.StagingTable WHERE IsValid = 1")
# Upsert (production-safe: DELETE + INSERT in a TRY/CATCH transaction)
fabric-sqlendpoint-execute_query(workspaceId, itemId,
"BEGIN TRY
BEGIN TRANSACTION;
DELETE FROM dbo.FactSales WHERE SaleDate = '2025-06-15';
INSERT INTO dbo.FactSales (SaleID, ProductID, SaleDate, Amount)
SELECT SaleID, ProductID, SaleDate, Amount FROM dbo.StagingTable WHERE SaleDate = '2025-06-15';
COMMIT TRANSACTION;
END TRY
BEGIN CATCH
IF @@TRANCOUNT > 0 ROLLBACK TRANSACTION;
THROW;
END CATCH")
# TRUNCATE (fast, preserves history — use instead of DELETE FROM)
fabric-sqlendpoint-execute_query(workspaceId, itemId,
"TRUNCATE TABLE dbo.StagingTable")Data Ingestion
# Parquet from ADLS Gen2 (uses caller's Entra ID credentials)
fabric-sqlendpoint-execute_query(workspaceId, itemId,
"COPY INTO dbo.FactSales
FROM 'https://storageacct.dfs.core.windows.net/container/sales/*.parquet'
WITH (FILE_TYPE = 'PARQUET')")
# CSV with options
fabric-sqlendpoint-execute_query(workspaceId, itemId,
"COPY INTO dbo.FactSales
FROM 'https://storageacct.dfs.core.windows.net/container/sales/*.csv'
WITH (FILE_TYPE = 'CSV', FIRSTROW = 2, FIELDTERMINATOR = ',', ROWTERMINATOR = '\n')")
# OPENROWSET + CTAS (transform-on-ingest)
fabric-sqlendpoint-execute_query(workspaceId, itemId,
"CREATE TABLE dbo.CleanData AS
SELECT id, UPPER(country) AS Country, CAST(amount AS decimal(19,4)) AS Amount
FROM OPENROWSET(BULK 'https://storageacct.dfs.core.windows.net/container/raw/*.parquet') AS raw
WHERE amount > 0")Advanced Authoring Patterns via MCP
Transactions
Transactions work within a single fabric-sqlendpoint-execute_query batch (no GO needed):
# Simple transaction — all in one batch
fabric-sqlendpoint-execute_query(workspaceId, itemId,
"BEGIN TRANSACTION;
INSERT INTO dbo.FactSales SELECT * FROM dbo.StagingTable WHERE IsValid = 1;
DELETE FROM dbo.StagingTable WHERE IsValid = 1;
COMMIT TRANSACTION;")
# Transaction with TRY/CATCH
fabric-sqlendpoint-execute_query(workspaceId, itemId,
"BEGIN TRY
BEGIN TRANSACTION;
INSERT INTO dbo.FactSales SELECT * FROM dbo.StagingTable WHERE IsValid = 1;
DELETE FROM dbo.StagingTable WHERE IsValid = 1;
COMMIT TRANSACTION;
END TRY
BEGIN CATCH
IF @@TRANCOUNT > 0 ROLLBACK TRANSACTION;
THROW;
END CATCH;")Schema Evolution
# Add nullable column (fast metadata op)
fabric-sqlendpoint-execute_query(workspaceId, itemId,
"ALTER TABLE dbo.FactSales ADD Region varchar(50) NULL")
# Drop column (April 2025+)
fabric-sqlendpoint-execute_query(workspaceId, itemId,
"ALTER TABLE dbo.FactSales DROP COLUMN Region")
# Change column type (CTAS + rename — robust; ALTER COLUMN is preview)
# Step 1: Create new table with correct type
fabric-sqlendpoint-execute_query(workspaceId, itemId,
"CREATE TABLE dbo.FactSales_New AS SELECT SaleID, ProductID, SaleDate, CAST(Amount AS decimal(19,2)) AS Amount FROM dbo.FactSales")
# Step 2: Rename tables
fabric-sqlendpoint-execute_query(workspaceId, itemId,
"EXEC sp_rename 'dbo.FactSales', 'FactSales_Old'")
fabric-sqlendpoint-execute_query(workspaceId, itemId,
"EXEC sp_rename 'dbo.FactSales_New', 'FactSales'")Warning: CTAS + rename loses time-travel history and security. Re-apply GRANT/DENY after swap.
Stored Procedures
# Create procedure (single batch, no GO needed)
fabric-sqlendpoint-execute_query(workspaceId, itemId,
"CREATE OR ALTER PROCEDURE dbo.sp_LoadFactSales @BatchDate date
AS
BEGIN
SET NOCOUNT ON;
DELETE FROM dbo.FactSales WHERE SaleDate = @BatchDate;
INSERT INTO dbo.FactSales (SaleID, ProductID, SaleDate, Amount)
SELECT SaleID, ProductID, SaleDate, Amount
FROM dbo.StagingTable WHERE SaleDate = @BatchDate;
END")
# Execute procedure
fabric-sqlendpoint-execute_query(workspaceId, itemId,
"EXEC dbo.sp_LoadFactSales @BatchDate = '2025-06-15'")
# Create view on Lakehouse SQLEP (read-only — views/funcs/procs allowed)
# lakehouseSqlEndpointId = lakehouse's properties.sqlEndpointProperties.id (NOT the lakehouse item id)
fabric-sqlendpoint-execute_query(workspaceId, lakehouseSqlEndpointId,
"CREATE OR ALTER VIEW dbo.vw_ActiveCustomers AS
SELECT CustomerID, Name, Email FROM dbo.Customers WHERE IsActive = 1")Time Travel and Recovery
# Query data as it existed at a specific time (UTC)
fabric-sqlendpoint-execute_query(workspaceId, itemId,
"SELECT TOP 100 * FROM dbo.FactSales
OPTION (FOR TIMESTAMP AS OF '2025-06-14T23:59:59.999')")
# Recover deleted data via CTAS
fabric-sqlendpoint-execute_query(workspaceId, itemId,
"CREATE TABLE dbo.FactSales_Recovered AS
SELECT * FROM dbo.FactSales
OPTION (FOR TIMESTAMP AS OF '2025-06-14T23:59:59.999')")Monitoring Authoring Operations
For full monitoring catalog see SQLDW-CONSUMPTION-CORE.md § Monitoring and Diagnostics.
# Active DML/DDL operations
fabric-sqlendpoint-execute_query(workspaceId, itemId,
"SELECT request_id, session_id, command, status, total_elapsed_time/1000 AS sec
FROM sys.dm_exec_requests
WHERE command IN ('INSERT','UPDATE','DELETE','MERGE','CREATE TABLE','COPY')
ORDER BY total_elapsed_time DESC")
# Recent ETL queries (last 24h)
fabric-sqlendpoint-execute_query(workspaceId, itemId,
"SELECT TOP 20 distributed_statement_id, login_name, label, total_elapsed_time_ms
FROM queryinsights.exec_requests_history
WHERE start_time >= DATEADD(HOUR,-24,GETUTCDATE()) AND label LIKE 'ETL_%'
ORDER BY total_elapsed_time_ms DESC")
# Failed writes (last 7d) — detect snapshot conflicts
fabric-sqlendpoint-execute_query(workspaceId, itemId,
"SELECT TOP 10 distributed_statement_id, command, start_time, status
FROM queryinsights.exec_requests_history
WHERE status='Failed' AND start_time >= DATEADD(DAY,-7,GETUTCDATE())
ORDER BY start_time DESC")
# Kill a stuck session (Admin role)
fabric-sqlendpoint-execute_query(workspaceId, itemId,
"KILL '<distributed_statement_id>'")Agent Integration Notes
GitHub Copilot CLI / MCP-enabled agents: Call
fabric-sqlendpoint-execute_query(workspaceId, itemId, query)directly. For COPY INTO, remind user about Storage Blob Data Reader role on the storage account.Multi-batch workflows: Call
fabric-sqlendpoint-execute_queryonce per logical batch. NoGOseparators — each call is one batch.Common agent pattern:
Discover schema (columns, types) via
fabric-sqlendpoint-execute_queryFormulate CTAS/DML with explicit CASTs
Execute via
fabric-sqlendpoint-execute_query(workspaceId, itemId, query)Verify result (row count, sample) via another
fabric-sqlendpoint-execute_querycallReport results to user
Rate limit awareness: If performing many sequential operations, space calls ~3s apart to avoid 429 errors. Consolidate multiple statements into one batch when they don't require
GObetween them.
Requirements and compatibility
Works with: Claude Code, Claude apps, OpenAI Codex, GitHub Copilot, Cursor, Gemini CLI, Kiro, OpenCode, Goose, Amp, Roo Code, JetBrains Junie, Factory Droid, Devin (ex-Windsurf), Mistral Vibe, OpenHands, Letta
“Works with” means the tool reads the open Agent Skills format; a skill written for one tool may use features others lack.
Needs: Needs an MCP server
Security
No issues found by our static scan· No issues found
A static scan is not a guarantee. Skills are third-party content: review a skill before you let an agent use it.
Attribution and licence
- Published by
- Microsoft
- Publisher
- Microsoft (Official)
- Source
- microsoft/skills-for-fabric · skills/sqldw-cli · commit f8fac11
- Licence
- MIT License (redistribution allowed)
- LICENSE (added by AutoGineer from LICENSE)
- ATTRIBUTION.md (written by AutoGineer)
- Synced
- Also distributed in
- microsoft/skills-for-fabric
AutoGineer is not affiliated with or endorsed by Microsoft.
Download ZIP
The ZIP holds the skill’s files, its licence files and an ATTRIBUTION.md. Download sqldw-cli.zip