> For the complete documentation index, see [llms.txt](https://docs.decube.io/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.decube.io/data-quality/how-to-set-up-monitors/set-up-volume-monitors.md).

# Set Up Volume Monitors

A Volume monitor tracks how many rows are added to a table in each scan window and alerts you when that increment falls outside the expected range. It is the right tool when you care about *how much* data arrived — not just whether it arrived.

## Freshness vs Volume: which to use

| Goal                                              | Use           |
| ------------------------------------------------- | ------------- |
| Detect that data **arrived** (or didn't)          | **Freshness** |
| Detect that the **right amount** of data arrived  | **Volume**    |
| Table receives data on a known schedule           | **Freshness** |
| Table grows by a predictable row count per period | **Volume**    |

If you need both signals, create one monitor of each type on the same table.

## How the Volume monitor works

The Volume monitor measures the **increment** — the number of new rows added since the previous scan — not the total row count of the table. The ML model trains on historical increments to establish a normal range, and raises an incident when a new increment falls outside it.

{% hint style="warning" %}
**Volume and row deletions**: if rows are deleted from a table and you use **All Records** mode, the measured increment can be negative or artificially small. This produces incorrect deltas. Use **Timestamp** row creation on tables where rows may be deleted.
{% endhint %}

### Backfill warning

If a large historical backfill is loaded into a monitored table, the increment for that scan period will be far above normal. The model will flag this as an anomaly. If you plan a backfill, either mute the monitor during the load or acknowledge the resulting incident as expected behaviour.

### Group by not supported

Volume monitors do not support Group By. If you need volume tracking broken down by a column value, use a Custom SQL monitor with a `GROUP BY` clause.

### Low-volume tables

On tables with very few rows per period, the Volume monitor may hit the [sparse-data threshold](/data-quality/anomaly-detection-explained.md#sparse-data-and-silent-skipping) (fewer than 5 valid points in 30 observations) and silently skip scans. For low-volume tables, a manual threshold (Absolute or Percentage) is more reliable than Smart Training.

***

## Before you begin

* You need at least one data source connected and a table available under that source.
* To use Smart Training, the table must have a timestamp column (or you must provide an SQL expression that produces one).

***

## Step 1: Set up

1. In the **Data Quality** module, go to the **Config** tab and select **Create**.
2. Select the **Volume** monitor card.
3. In the **Create a New Monitor** form, select your **Source** (Schema is optional) and **Dataset**.
4. Choose **Monitor mode**: **Scheduled** or **On-Demand**.
5. Click **Proceed to Monitor Setup**.

***

## Step 2: Configure — Scheduled monitor

| Field                   | Description                                                                                                                                                                                   |
| ----------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| **Monitor Name**        | A descriptive name for this monitor.                                                                                                                                                          |
| **Monitor Description** | Optional.                                                                                                                                                                                     |
| **Row Creation**        | How Decube identifies new rows: **Timestamp** (select a timestamp column), **SQL Expression** (provide an expression that produces a timestamp), or **All Records**.                          |
| **Smart Training**      | Toggle on to train the model on historical increments. Requires Timestamp or SQL Expression.                                                                                                  |
| **Frequency**           | How often the monitor scans. See [Custom Scheduling for Monitors](https://github.com/DecubeIO/decube-docs/blob/public/data-quality/how-to-set-up-monitors/custom-scheduling-for-monitors.md). |
| **Incident Level**      | Severity assigned to incidents this monitor opens.                                                                                                                                            |

{% hint style="warning" %}
**All Records** mode does not support Smart Training and can produce incorrect deltas if rows are deleted. Use Timestamp or SQL Expression row creation whenever possible.
{% endhint %}

### SQL Expression

Use an SQL Expression when your table stores timestamps in a non-standard format. See the [SQL Expression examples on the Freshness setup page](/data-quality/how-to-set-up-monitors/set-up-freshness-monitors.md#sql-expression) for common conversion patterns. Validating the expression before saving is required.

### Notifications

Turn on **Notify default channel** to route incidents to a specific email or Slack channel. Click **Submit** to create the monitor.

***

## Step 2: Configure — On-Demand monitor

On-Demand monitors do not use Smart Training, Auto Threshold, or frequency scheduling.

| Field                   | Description                                        |
| ----------------------- | -------------------------------------------------- |
| **Monitor Name**        | A descriptive name.                                |
| **Monitor Description** | Optional.                                          |
| **Row Creation**        | **Timestamp** or **SQL Expression** only.          |
| **Lookback Period**     | The time window to check when the monitor runs.    |
| **Incident Level**      | Severity assigned to incidents this monitor opens. |

To finish:

* Click **Save** to create the monitor without running it immediately.
* Click **Save and Run** to create and run the monitor straight away.

After creation, you can run the monitor again from **All Monitors** by clicking the ellipsis (︙) and selecting **View Monitor**, then **Run once**.

***

## Related pages

{% content-ref url="/pages/YpzBR4Fms5X6aZfHSJXj" %}
[Set Up Freshness Monitors](/data-quality/how-to-set-up-monitors/set-up-freshness-monitors.md)
{% endcontent-ref %}

{% content-ref url="/pages/12tZSWlWRX4XEXBTD4L6" %}
[How Anomaly Detection Works](/data-quality/anomaly-detection-explained.md)
{% endcontent-ref %}

{% content-ref url="/pages/KgXixMx9V2joZYvvAjL9" %}
[Retraining Monitors](/data-quality/monitor-configuration-settings/retraining-monitors.md)
{% endcontent-ref %}


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.decube.io/data-quality/how-to-set-up-monitors/set-up-volume-monitors.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
