> ## Documentation Index
> Fetch the complete documentation index at: https://docs.dqlabs.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Overview

> What Usage metrics are in Prizm — track daily query volume against a database or schema to reveal workload trends and unexpected spikes.

<script type="application/ld+json">
  {`{
            "@context": "https://schema.org",
            "@type": "TechArticle",
            "headline": "Usage Metrics Overview",
            "description": "What Usage metrics are in Prizm - track daily query volume against a database or schema to reveal workload trends and unexpected spikes.",
            "url": "https://docs.dqlabs.ai/architecture/metrics/usage/overview",
            "publisher": {
              "@type": "Organization",
              "name": "DQLabs Inc",
              "logo": "https://media.brand.dev/332adc35-5bc4-4d2b-bf78-256aa4a5e414.svg"
            }
            }`}
</script>

## What is a Usage metric?

Usage metrics track **how many queries are executed daily** against a database or schema. They provide visibility into workload volume trends, helping teams understand growth patterns and detect sudden spikes or unexpected drops in query activity.

**Type:** Automatic — Usage metrics are enabled on all connected database and schema objects as part of the Cost & Performance profile. No configuration is required to activate them.

Usage metrics answer the question: *How much query activity is this asset receiving daily?*

Prizm collects query count data from Snowflake's `ACCOUNT_USAGE.QUERY_HISTORY` view on each performance job run (every 24 hours). Results are aggregated per database and schema, then trended over time. Anomaly detection alerts when daily query volume deviates significantly from the established baseline.

### Where to find Usage metrics

Usage metrics live on every database and schema asset page. To view them:

1. Navigate to **Asset** and open any database or schema asset.
2. Click the **Metric** tab.
3. Select the **USAGE** filter chip.

<Frame>
  <img src="https://mintlify.s3.us-west-1.amazonaws.com/dqlabs/images/metrics/usage/asset-metric-usage-filter.png" alt="Usage metric in the USAGE filter on the Asset Metric tab" />
</Frame>

### Metrics

| Metric                | Level             | Subcategory | Dimension   | Description                                                                                                                                                                                                                                                                                        |
| --------------------- | ----------------- | ----------- | ----------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| Total Queries Per Day | Database / Schema | Usage       | Utilization | Total number of queries executed against the database or schema per day, counted from `QUERY_HISTORY`. Tracks overall workload volume over time. A sudden drop can indicate a pipeline failure or access issue; an unexpected spike may indicate a runaway process or new high-frequency consumer. |

### How Usage monitoring works

Prizm reads from `SNOWFLAKE.ACCOUNT_USAGE.QUERY_HISTORY` on each performance job run and counts all queries in the last 24-hour window (with a 45-minute overlap for Snowflake latency). The daily total is stored per database and schema, trended over time, and evaluated against a statistical baseline.

Query volume is expected to follow weekly patterns — higher on weekdays, lower on weekends, with end-of-month spikes for reporting workloads. Prizm's statistical model adapts to these recurring patterns and alerts on deviations that fall outside the expected range.

### Example use cases

**Detecting a pipeline failure:** A nightly ETL pipeline that runs hundreds of transformation queries stops executing due to an upstream dependency failure. Total Queries Per Day drops to near zero. Prizm fires a Usage alert in the next collection cycle — before any downstream dashboards show stale data.

**Identifying a runaway process:** A misconfigured reporting tool begins polling a production database every 30 seconds instead of every 5 minutes. Total Queries Per Day spikes from 2,000 to 200,000. Prizm flags the volume anomaly, allowing the platform team to identify and throttle the offending connection.

**Tracking adoption growth:** After a new self-service analytics platform is launched, Total Queries Per Day climbs steadily week-over-week as more analysts onboard. Prizm surfaces this trend, providing evidence to justify warehouse capacity increases ahead of projected growth.

<Tip>
  A drop in Total Queries Per Day combined with no change in Query Success Rate often means the workload stopped running entirely — check pipeline scheduler logs rather than query error logs. If both drop together, a permission change or connectivity issue may be blocking access.
</Tip>

<Card title="Configure" icon="sliders" href="/architecture/metrics/usage/configure">
  Set thresholds, view the metric detail page, and understand Usage alerts.
</Card>
