mirror of
https://github.com/postgres/postgres.git
synced 2025-07-28 23:42:10 +03:00
Add geometry/range functions to support BRIN inclusion
This commit adds the following functions: box(point) -> box bound_box(box, box) -> box inet_same_family(inet, inet) -> bool inet_merge(inet, inet) -> cidr range_merge(anyrange, anyrange) -> anyrange The first of these is also used to implement a new assignment cast from point to box. These functions are the first part of a base to implement an "inclusion" operator class for BRIN, for multidimensional data types. Author: Emre Hasegeli Reviewed by: Andreas Karlsson
This commit is contained in:
@ -79,6 +79,12 @@ SELECT '' AS twenty, b.f1 / p.f1 AS rotation
|
||||
FROM BOX_TBL b, POINT_TBL p
|
||||
WHERE (p.f1 <-> point '(0,0)') >= 1;
|
||||
|
||||
SELECT f1::box
|
||||
FROM POINT_TBL;
|
||||
|
||||
SELECT bound_box(a.f1, b.f1)
|
||||
FROM BOX_TBL a, BOX_TBL b;
|
||||
|
||||
--
|
||||
-- Paths
|
||||
--
|
||||
|
Reference in New Issue
Block a user