warehouse
Manage warehouses and run SQL queries
Authentication scope: fabric
List warehouses in a workspace
fabio warehouse list --workspace <value>| Flag | Type | Required | Description |
|---|---|---|---|
--workspace |
string |
Yes | Workspace ID |
Output fields: id, displayName, description
Read-only · Returns list
Show details of a warehouse
fabio warehouse show --workspace <value> --id <value>| Flag | Type | Required | Description |
|---|---|---|---|
--workspace |
string |
Yes | Workspace ID |
--id |
string |
Yes | Warehouse ID |
Output fields: id, displayName, description, properties
Read-only · Returns object
create
Section titled “create”Create a new warehouse
fabio warehouse create --workspace <value> --name <value>| Flag | Type | Required | Description |
|---|---|---|---|
--workspace |
string |
Yes | Workspace ID |
--name |
string |
Yes | Warehouse display name |
--description |
string |
No | Optional description |
--sensitivity-label |
string |
No | Sensitivity label ID to apply on creation |
--collation |
string |
No | Collation for the warehouse (create-time only). Values: Latin1_General_100_BIN2_UTF8 (case-sensitive, default) or Latin1_General_100_CI_AS_KS_WS_SC_UTF8 (case-insensitive) |
Examples
fabio warehouse create --workspace $WS --name "SalesWarehouse"Output fields: id, displayName
Mutates state · Returns object
update
Section titled “update”Update warehouse properties (name and/or description)
fabio warehouse update --workspace <value> --id <value>| Flag | Type | Required | Description |
|---|---|---|---|
--workspace |
string |
Yes | Workspace ID |
--id |
string |
Yes | Warehouse ID |
--name |
string |
No | New display name |
--description |
string |
No | New description |
Mutates state · Returns object
delete
Section titled “delete”Delete a warehouse
fabio warehouse delete --workspace <value> --id <value>| Flag | Type | Required | Description |
|---|---|---|---|
--workspace |
string |
Yes | Workspace ID |
--id |
string |
Yes | Warehouse ID |
--hard-delete |
bool |
No | Permanently delete (cannot be recovered) |
Mutates state · Destructive · Returns void
Execute a SQL query against a warehouse or SQL endpoint
fabio warehouse query --workspace <value> --id <value>| Flag | Type | Required | Description |
|---|---|---|---|
--workspace |
string |
Yes | Workspace ID |
--id |
string |
Yes | Warehouse or Lakehouse ID |
--sql |
string |
No | SQL query to execute (prefix with @ to read from file, omit to read from stdin) |
--via-mcp |
bool |
No | Execute via the remote Fabric DW MCP server (Fabric token, no direct TDS/1433) |
Examples
fabio warehouse query --workspace $WS --id $WH --sql "SELECT TOP 100 * FROM dbo.fact_sales ORDER BY order_date DESC"fabio warehouse query --workspace $WS --id $WH --sql @queries/monthly_report.sqlMutates state · Returns list
Capture the estimated execution plan (SHOWPLAN_XML) without executing the query
fabio warehouse plan --workspace <value> --id <value>| Flag | Type | Required | Description |
|---|---|---|---|
--workspace |
string |
Yes | Workspace ID |
--id |
string |
Yes | Warehouse or Lakehouse ID |
--sql |
string |
No | SQL query to plan (prefix with @ to read from file, omit to read from stdin) |
Read-only · Returns object
mcp-url
Section titled “mcp-url”Print the remote Fabric Data Warehouse MCP server URLs (item-scoped + global) for agent consumption
fabio warehouse mcp-url --workspace <value> --id <value>| Flag | Type | Required | Description |
|---|---|---|---|
--workspace |
string |
Yes | Workspace ID |
--id |
string |
Yes | Warehouse ID |
Examples
fabio warehouse mcp-url --workspace $WS --id $WHRead-only · Returns object
list-tables
Section titled “list-tables”List tables and views in a warehouse (from INFORMATION_SCHEMA.TABLES)
fabio warehouse list-tables --workspace <value> --id <value>| Flag | Type | Required | Description |
|---|---|---|---|
--workspace |
string |
Yes | Workspace ID |
--id |
string |
Yes | Warehouse or Lakehouse ID |
--schema |
string |
No | Only list tables in this schema (e.g. dbo) |
Examples
fabio warehouse list-tables --workspace $WS --id $WH --schema dboRead-only · Returns list
describe-table
Section titled “describe-table”Describe the columns of a table (from INFORMATION_SCHEMA.COLUMNS)
fabio warehouse describe-table --workspace <value> --id <value> --table <value>| Flag | Type | Required | Description |
|---|---|---|---|
--workspace |
string |
Yes | Workspace ID |
--id |
string |
Yes | Warehouse or Lakehouse ID |
--table |
string |
Yes | Table name, optionally schema-qualified (e.g. dbo.Customers or Customers) |
Examples
fabio warehouse describe-table --workspace $WS --id $WH --table dbo.OrdersRead-only · Returns list
copy-into
Section titled “copy-into”Bulk-load files from Azure storage / OneLake into a table with COPY INTO
fabio warehouse copy-into --workspace <value> --id <value> --table <value> --source <value> --file-type <value>| Flag | Type | Required | Description |
|---|---|---|---|
--workspace |
string |
Yes | Workspace ID |
--id |
string |
Yes | Warehouse ID |
--table |
string |
Yes | Target table, optionally schema-qualified (e.g. dbo.Orders). Must already exist |
--source |
string |
Yes | Source location: HTTPS Azure storage / OneLake URL (file or folder/wildcard) |
--file-type |
string |
Yes | File format of the source data |
--columns |
string |
No | Optional target column list (comma-separated), matching the source order |
--field-terminator |
string |
No | CSV field terminator (e.g. ,) |
--row-terminator |
string |
No | CSV row terminator (e.g. \n) |
--first-row |
integer |
No | CSV first data row (e.g. 2 to skip a header row) |
--encoding |
string |
No | CSV encoding (UTF8 or UTF16) |
--sas-token |
string |
No | SAS token for the source storage (omit to use the caller’s Entra ID) |
--auth-mode |
enum |
No | Source authentication mode. entra-id (default) uses the caller’s Entra identity; sas uses –sas-token; workspace-identity uses the Fabric workspace’s managed identity (no secret; the workspace identity must be granted access to the source, e.g. Storage Blob Data Reader) One of: entra-id, sas, workspace-identity. |
Examples
fabio warehouse copy-into --workspace $WS --id $WH --table dbo.Orders --source https://acct.dfs.core.windows.net/c/data/*.parquet --file-type PARQUETfabio warehouse copy-into --workspace $WS --id $WH --table dbo.Raw --source https://acct.blob.core.windows.net/c/data.csv --file-type CSV --first-row 2 --dry-runMutates state · Returns object
connection-string
Section titled “connection-string”Get the connection string for a warehouse
fabio warehouse connection-string --workspace <value> --id <value>| Flag | Type | Required | Description |
|---|---|---|---|
--workspace |
string |
Yes | Workspace ID |
--id |
string |
Yes | Warehouse ID |
--guest-tenant-id |
string |
No | Guest tenant ID (for cross-tenant access) |
--private-link-type |
string |
No | Private link type (for private endpoint access) |
Examples
fabio warehouse connection-string --workspace $WS --id $WHRead-only · Returns object
get-sql-pools-config
Section titled “get-sql-pools-config”Get SQL pools configuration for a workspace
fabio warehouse get-sql-pools-config --workspace <value>| Flag | Type | Required | Description |
|---|---|---|---|
--workspace |
string |
Yes | Workspace ID |
Read-only · Returns object
update-sql-pools-config
Section titled “update-sql-pools-config”Update SQL pools configuration for a workspace
fabio warehouse update-sql-pools-config --workspace <value>| Flag | Type | Required | Description |
|---|---|---|---|
--workspace |
string |
Yes | Workspace ID |
--file |
string |
No | Path to JSON file with configuration (prefix with @) |
--content |
string |
No | Inline JSON content |
Mutates state · Returns void
get-audit-settings
Section titled “get-audit-settings”Get SQL audit settings for a warehouse
fabio warehouse get-audit-settings --workspace <value> --id <value>| Flag | Type | Required | Description |
|---|---|---|---|
--workspace |
string |
Yes | Workspace ID |
--id |
string |
Yes | Warehouse ID |
Read-only · Returns object
update-audit-settings
Section titled “update-audit-settings”Update SQL audit settings for a warehouse
fabio warehouse update-audit-settings --workspace <value> --id <value>| Flag | Type | Required | Description |
|---|---|---|---|
--workspace |
string |
Yes | Workspace ID |
--id |
string |
Yes | Warehouse ID |
--state |
string |
No | Audit state (e.g. Enabled, Disabled) |
--retention-days |
integer |
No | Retention period in days |
--audit-actions |
string |
No | Comma-separated list of audit actions |
--predicate-expression |
string |
No | Predicate expression without WHERE (max 3000 chars; empty string removes it) |
Mutates state · Returns void
set-audit-actions
Section titled “set-audit-actions”Set audit actions and groups for a warehouse
fabio warehouse set-audit-actions --workspace <value> --id <value>| Flag | Type | Required | Description |
|---|---|---|---|
--workspace |
string |
Yes | Workspace ID |
--id |
string |
Yes | Warehouse ID |
--actions |
array |
No | Comma-separated list of audit actions and groups |
Mutates state · Returns void
list-restore-points
Section titled “list-restore-points”List restore points for a warehouse
fabio warehouse list-restore-points --workspace <value> --id <value>| Flag | Type | Required | Description |
|---|---|---|---|
--workspace |
string |
Yes | Workspace ID |
--id |
string |
Yes | Warehouse ID |
Examples
fabio warehouse list-restore-points --workspace $WS --id $WH -o tableRead-only · Returns list
create-restore-point
Section titled “create-restore-point”Create a restore point for a warehouse
fabio warehouse create-restore-point --workspace <value> --id <value>| Flag | Type | Required | Description |
|---|---|---|---|
--workspace |
string |
Yes | Workspace ID |
--id |
string |
Yes | Warehouse ID |
--name |
string |
No | Display name for the restore point |
--description |
string |
No | Optional description for the restore point |
Examples
fabio warehouse create-restore-point --workspace $WS --id $WH --name "pre-migration"Mutates state · Returns object
show-restore-point
Section titled “show-restore-point”Show details of a restore point
fabio warehouse show-restore-point --workspace <value> --id <value> --restore-point-id <value>| Flag | Type | Required | Description |
|---|---|---|---|
--workspace |
string |
Yes | Workspace ID |
--id |
string |
Yes | Warehouse ID |
--restore-point-id |
string |
Yes | Restore point ID |
Read-only · Returns object
update-restore-point
Section titled “update-restore-point”Update a restore point
fabio warehouse update-restore-point --workspace <value> --id <value> --restore-point-id <value>| Flag | Type | Required | Description |
|---|---|---|---|
--workspace |
string |
Yes | Workspace ID |
--id |
string |
Yes | Warehouse ID |
--restore-point-id |
string |
Yes | Restore point ID |
--name |
string |
No | New display name for the restore point |
--description |
string |
No | New description for the restore point |
Mutates state · Returns void
delete-restore-point
Section titled “delete-restore-point”Delete a restore point
fabio warehouse delete-restore-point --workspace <value> --id <value> --restore-point-id <value>| Flag | Type | Required | Description |
|---|---|---|---|
--workspace |
string |
Yes | Workspace ID |
--id |
string |
Yes | Warehouse ID |
--restore-point-id |
string |
Yes | Restore point ID |
Mutates state · Destructive · Returns void
restore-to-point
Section titled “restore-to-point”Restore a warehouse to a restore point
fabio warehouse restore-to-point --workspace <value> --id <value> --restore-point-id <value>| Flag | Type | Required | Description |
|---|---|---|---|
--workspace |
string |
Yes | Workspace ID |
--id |
string |
Yes | Warehouse ID |
--restore-point-id |
string |
Yes | Restore point ID |
Mutates state · Destructive · Long-running operation · Returns object
queries-running
Section titled “queries-running”List currently running queries on a warehouse (add –follow to watch live)
fabio warehouse queries-running --workspace <value> --id <value>| Flag | Type | Required | Description |
|---|---|---|---|
--workspace |
string |
Yes | Workspace ID |
--id |
string |
Yes | Warehouse or Lakehouse ID |
--follow |
bool |
No | Continuously poll and stream NDJSON until --max-duration, --limit, or Ctrl-C (watch active queries live). The command always terminates |
--interval |
integer |
No | Seconds between polls in --follow mode (default 5) |
--max-duration |
integer |
No | Total seconds to follow before stopping — the agent-safety bound (default 60) |
--dedup-column |
string |
No | In --follow, only emit queries whose value in this column exceeds the max seen so far (e.g. session_id); without it each cycle re-emits the full snapshot (watch semantics) |
Read-only · Returns list
queries-frequent
Section titled “queries-frequent”List frequently-run queries (from queryinsights.frequently_run_queries)
fabio warehouse queries-frequent --workspace <value> --id <value>| Flag | Type | Required | Description |
|---|---|---|---|
--workspace |
string |
Yes | Workspace ID |
--id |
string |
Yes | Warehouse or Lakehouse ID |
--top |
integer |
No | Maximum rows to return (default: 100) |
Read-only · Returns object
queries-long-running
Section titled “queries-long-running”List long-running queries (from queryinsights.long_running_queries)
fabio warehouse queries-long-running --workspace <value> --id <value>| Flag | Type | Required | Description |
|---|---|---|---|
--workspace |
string |
Yes | Workspace ID |
--id |
string |
Yes | Warehouse or Lakehouse ID |
--top |
integer |
No | Maximum rows to return (default: 100) |
Read-only · Returns object
queries-history
Section titled “queries-history”List completed query history (from queryinsights.exec_requests_history)
fabio warehouse queries-history --workspace <value> --id <value>| Flag | Type | Required | Description |
|---|---|---|---|
--workspace |
string |
Yes | Workspace ID |
--id |
string |
Yes | Warehouse or Lakehouse ID |
--top |
integer |
No | Maximum rows to return (default: 100) |
--label |
string |
No | Filter to queries tagged with this OPTION (LABEL = ‘…’) value |
Read-only · Returns object
queries-kill
Section titled “queries-kill”Kill a running query session by session ID
fabio warehouse queries-kill --workspace <value> --id <value> --session-id <value>| Flag | Type | Required | Description |
|---|---|---|---|
--workspace |
string |
Yes | Workspace ID |
--id |
string |
Yes | Warehouse or Lakehouse ID |
--session-id |
integer |
Yes | Session ID to terminate |
Mutates state · Destructive · Returns object
pool-insights
Section titled “pool-insights”Report SQL pool state changes and sustained pressure events (from queryinsights.sql_pool_insights)
fabio warehouse pool-insights --workspace <value> --id <value>| Flag | Type | Required | Description |
|---|---|---|---|
--workspace |
string |
Yes | Workspace ID |
--id |
string |
Yes | Warehouse or Lakehouse ID |
--top |
integer |
No | Maximum rows to return (default: 100) |
Read-only · Returns object
statistics-list
Section titled “statistics-list”List user-defined statistics on a warehouse or SQL endpoint
fabio warehouse statistics-list --workspace <value> --id <value>| Flag | Type | Required | Description |
|---|---|---|---|
--workspace |
string |
Yes | Workspace ID |
--id |
string |
Yes | Warehouse or Lakehouse ID |
--table |
string |
No | Filter by table name (schema.table) |
Read-only · Returns object
statistics-show
Section titled “statistics-show”Show details of a statistic (header, density vector, histogram)
fabio warehouse statistics-show --workspace <value> --id <value> --name <value>| Flag | Type | Required | Description |
|---|---|---|---|
--workspace |
string |
Yes | Workspace ID |
--id |
string |
Yes | Warehouse or Lakehouse ID |
--name |
string |
Yes | Statistic name to inspect |
Read-only · Returns object
statistics-create
Section titled “statistics-create”Create a user-defined statistic on a column
fabio warehouse statistics-create --workspace <value> --id <value> --table <value> --column <value> --name <value>| Flag | Type | Required | Description |
|---|---|---|---|
--workspace |
string |
Yes | Workspace ID |
--id |
string |
Yes | Warehouse or Lakehouse ID |
--table |
string |
Yes | Schema-qualified table name (e.g., dbo.orders) |
--column |
string |
Yes | Column name to create statistics on |
--name |
string |
Yes | Name for the new statistic |
Mutates state · Returns object
statistics-update
Section titled “statistics-update”Update (refresh) an existing statistic
fabio warehouse statistics-update --workspace <value> --id <value> --name <value>| Flag | Type | Required | Description |
|---|---|---|---|
--workspace |
string |
Yes | Workspace ID |
--id |
string |
Yes | Warehouse or Lakehouse ID |
--name |
string |
Yes | Statistic name to update |
Mutates state · Returns object
statistics-delete
Section titled “statistics-delete”Delete a user-defined statistic
fabio warehouse statistics-delete --workspace <value> --id <value> --name <value>| Flag | Type | Required | Description |
|---|---|---|---|
--workspace |
string |
Yes | Workspace ID |
--id |
string |
Yes | Warehouse or Lakehouse ID |
--name |
string |
Yes | Statistic name to delete |
Mutates state · Returns object
get-retention
Section titled “get-retention”Report the configured data-retention (time-travel) period, in days
fabio warehouse get-retention --workspace <value> --id <value>| Flag | Type | Required | Description |
|---|---|---|---|
--workspace |
string |
Yes | Workspace ID |
--id |
string |
Yes | Warehouse ID |
Read-only · Returns object
set-retention
Section titled “set-retention”Configure the data-retention (time-travel) period, in days (1-120)
fabio warehouse set-retention --workspace <value> --id <value> --days <value>| Flag | Type | Required | Description |
|---|---|---|---|
--workspace |
string |
Yes | Workspace ID |
--id |
string |
Yes | Warehouse ID |
--days |
integer |
Yes | Retention period in days (1-120). Decreasing it is irreversible (older history is garbage-collected) |
Mutates state · Destructive · Returns void
