Range partitioning
Range partitioning assigns records to partitions according to non-overlapping, ordered intervals of one or more partition-key values.
Latency
Key range partitioning assigns records to partitions according to contiguous ranges of partitioning-key values.
- How it is used
- Assigns records to horizontal partitions by key interval to support scans over ordered or predictable ranges.
- How deep it goes
- Explains range assignment through an ID example and examines distribution failures and remedies, without giving a configuration procedure.
- Examples
- Uses ID ranges and unevenly distributed user zip codes to show partition assignment and imbalance.
- What you can do after
- Evaluate/understand it by weighing range-scan needs against key distribution, partition size, and the cost of rebalancing.
PostgreSQL Mistakes and How to Avoid Them
Range partitioning assigns rows to partitions according to ordered lower and upper bounds of a partition key.
- How it is used
- Uses ordered key ranges to organize large time-oriented tables and simplify retention maintenance.
- How deep it goes
- Explains range bounds, partition creation, pruning, data migration, query measurement, and partition replacement for deletion.
- Examples
- Demonstrates monthly timestamp partitions for payments, EXPLAIN measurements, bulk copying, deletion, and dropping an obsolete partition.
- What you can do after
- Operate/configure monthly PostgreSQL partitions and diagnose pruning and maintenance performance with EXPLAIN and timing.
Read how PostgreSQL Mistakes and How to Avoid Them explains range partitioning →
Related concepts
- dataset splitkind of · A dataset split is the division of a dataset into distinct subsets assigned different purposes, such as training, validation, or testing.
- partitioning keyconfigures · A partitioning key is a value or attribute used to determine which partition stores or receives a record or data item.
- key hash partitioningalternative to · Key hash partitioning assigns each record or item to a partition according to a hash computed from its partitioning key.
These guides are generated from the text of Manning books by Manning's knowledge graph and link to the sections they draw on. The full books are available on liveBook and at manning.com.

