sqldw-consumption-cli

Query Microsoft Fabric SQL endpoints with read-only T-SQL via CLI.

14|3|Updated Mar 13, 2026
One-click install
npx skills add https://github.com/patrikborosch/AnalyticsPlatformAgents --skill sqldw-consumption-cli-patrikborosch
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: sqldw-consumption-cli
Source: https://github.com/patrikborosch/AnalyticsPlatformAgents/tree/main/creator/skills/sqldw-consumption-cli
Command: npx skills add https://github.com/patrikborosch/AnalyticsPlatformAgents --skill sqldw-consumption-cli-patrikborosch

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

This Skill removes the friction of accessing data in Microsoft Fabric SQL endpoints (Data Warehouses, Lakehouse SQL Endpoints, Mirrored Databases) by providing a streamlined CLI-based workflow for T-SQL queries, eliminating the need for custom tooling or manual UI navigation for ad-hoc data access and exploration.

Core Features & Use Cases

  • Read-Only T-SQL Query Execution: Run ad-hoc, parameterized, or scripted T-SQL queries against any Fabric SQL endpoint directly from the command line.
  • Schema & Data Discovery: Quickly explore table schemas, column metadata, row counts, and security configurations to understand dataset structure without leaving the CLI.
  • Data Export & Performance Monitoring: Export query results to CSV/JSON formats, monitor active query performance, and investigate slow queries using built-in Fabric diagnostic views.
  • Use Case Example: An analytics engineer can use this Skill to count rows in a lakehouse table, generate a T-SQL script for a monthly sales aggregation report, or export filtered customer data to CSV for downstream analysis.

Quick Start

Use the sqldw-consumption-cli skill to run a T-SQL query that counts the total number of rows in the 'FactSales' table in your Fabric Data Warehouse and save the results to a CSV file.

Frequently Asked Questions about sqldw-consumption-cli

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

FAQPage Schema
How do I run T-SQL queries on Microsoft Fabric Data Warehouse from the command line?

To run T-SQL queries on Microsoft Fabric Data Warehouse from the command line, you can use a CLI tool to execute read-only ad-hoc queries directly against the SQL endpoints. This requires the Go-based sqlcmd CLI and Azure CLI authentication to establish the connection.

Can I query a Fabric Lakehouse SQL endpoint using sqlcmd?

Yes, you can query a Fabric Lakehouse SQL endpoint using sqlcmd. The CLI supports read-only T-SQL querying of data stored in Lakehouse SQL endpoints, Mirrored Databases, and Data Warehouses by establishing TDS connections on port 1433.

What's the best way to export Fabric Data Warehouse query results to CSV without the UI?

The best way to export Fabric Data Warehouse query results to CSV without the UI is by using a CLI-based T-SQL querying tool. It allows you to execute targeted queries and save the structured data output directly to CSV or JSON formats for downstream analysis.

Do I need Azure CLI authentication to access Fabric SQL endpoints via CLI?

Yes, you need Azure CLI authentication to access Fabric SQL endpoints via CLI. Along with the Go-based sqlcmd CLI tool, Azure CLI authentication is required to securely establish TDS connections to the Fabric workspace resources on port 1433.

How do I discover table schemas and row counts in a Fabric Data Warehouse?

To discover table schemas and row counts in a Fabric Data Warehouse, you can run schema discovery and row count validation queries via the command line. This allows you to quickly explore table schemas, column metadata, and dataset structure without leaving the CLI.

Can I monitor slow query performance in Fabric using T-SQL command line tools?

Yes, you can monitor slow query performance in Fabric using T-SQL command line tools. The CLI supports performance monitoring by querying built-in Fabric diagnostic views to investigate active queries and identify performance bottlenecks directly from the terminal.