# Azure Synapse SQL Pool Idle

> Flags Synapse dedicated SQL pools with no active queries and low DWU use, and prices pausing as the compute share only.

Source: https://zop.dev/integrations/azure/recommendations/azure-synapse-sql-pool-idle

---

## Compute and storage are billed apart in a dedicated pool

A Synapse dedicated SQL pool separates compute from storage, and Microsoft's
[compute management guide](https://learn.microsoft.com/en-us/azure/synapse-analytics/sql-data-warehouse/sql-data-warehouse-manage-compute-overview)
spells out the billing consequence: pricing for compute and storage is separate. When you pause
a pool, Data Warehouse Unit costs are zero during the pause, while data storage is not affected and
keeps its data. Resuming brings the DWU charge back.

An idle pool left running is therefore paying for its full DWU level for nothing. Pausing it is
safe for the data, but it is not free: storage continues to bill.

## Checking query activity on a pool

```bash
az synapse sql pool list --workspace-name my-workspace --resource-group my-rg \
  --query "[].{name:name, sku:sku.name, status:status}" -o table

az monitor metrics list --resource <sql-pool-resource-id> \
  --metric ActiveQueries DWUUsedPercent --offset 30d --interval PT24H --aggregation Average Maximum
```

The DWU used percentage metric is the higher of CPU and data IO percentage, a good cross-check that nothing is
running in the background.

## Gates on query and DWU activity

1. The pool is online (Succeeded).
2. The `ActiveQueries` series is present and covers at least 7 days, so a pool created this week
   is not paused on an empty chart.
3. `ActiveQueries` is zero on both average and peak over the full history available, not only the
   last few days.
4. When the DWU used percentage metric is reported, it is at or below 5%. Higher DWU use with no visible queries
   points at background or maintenance work and cancels the finding.
5. The pool has a known monthly cost above zero.

Pipeline run counts from the workspace, when present, appear in the description as extra context
but never decide the result.

## Pools that keep running

Without the `ActiveQueries` series there is no finding. Any query, or DWU use above 5%, also clears
the pool. Tags describing pipeline runs or Spark jobs are no longer read, since nothing
guaranteed they were accurate.

## Saving covers compute only

```text
saving = current monthly pool cost x compute share
cost after fix = current monthly pool cost - saving   (storage keeps billing)
```

The cost after the fix is never zero, because pausing leaves storage charges in place.

## Pausing the idle pool

1. Confirm no scheduled loads or reports are due; pausing cancels any running or queued operations.
2. Pause it: `az synapse sql pool pause --name my-pool --workspace-name my-workspace --resource-group my-rg`.
3. Resume with `az synapse sql pool resume` when needed, then restart workload queries.
4. If the pool must stay reachable, Microsoft suggests scaling it to the smallest size instead,
   for example with
   `az synapse sql pool update --name my-pool --workspace-name my-workspace --resource-group my-rg --performance-level DW100c`.
