← Back to Glossary

Zone map (min-max index)

A zone map, or min-max index, is a lightweight index that stores the minimum and maximum value of a column for each block of data, letting queries skip blocks that can't match a filter.

Overview

A zone map (also called a block range index or min-max index) is one of the cheapest and most effective pruning techniques in analytical databases. For each contiguous block of rows, the database records the minimum and maximum value of a column within that block. When a query filters on that column, the engine checks each block's min-max range against the filter and skips any block whose range can't possibly contain a match — without reading the block's actual data at all.

How Zone Maps Work

Given a filter like WHERE order_date = '2024-06-01', a block whose recorded range is 2023-01-01 to 2023-12-31 can be skipped immediately, since the filter value falls entirely outside that range. Zone maps are cheap to build and store — just two values per block per column — and cheap to check, but they only help when data has some locality: the more a column is sorted or naturally clustered within blocks, the more values zone maps can prune.

Zone Maps vs. Traditional Indexes

Unlike a B-tree index, which points to exact row locations, a zone map only tells you whether a block might contain a match. It can't tell you which row within the block, so it's purely a pruning device that reduces I/O — the block still has to be scanned if it passes the min-max check.

DuckDB's Zone Maps

DuckDB automatically maintains a min-max index for every column of every general-purpose data type, for each row group, with no manual index creation required. Combined with predicate pushdown, this lets DuckDB skip entire row groups — whether stored natively or in Parquet files — that can't satisfy a query's WHERE clause. Because these zone maps are most effective on ordered data, loading data pre-sorted on frequently filtered columns can substantially improve how much a query can prune.

Related terms

FAQS

A regular index like a B-tree points to specific rows. A zone map only stores the min and max value per block, so it can prove a block has no match and skip it, but it can't point to individual rows within a block that does match.

No. DuckDB automatically maintains a min-max zone map for every column in every row group without any manual index creation.