Skip to main content
range_term is the equivalent of Postgres’ operators over range types. It supports operations like range containment, overlap, and intersection.

Term Within

In this example, weight_range is an int4range type. The following query finds all rows where weight_range contains 1:

Range Intersects

The following query finds all ranges that share at least one common point with the query range:

Range Contains

The following query finds all ranges that are contained by the query range:

Range Within

The following query finds all ranges that contain the query range: