From: | Alvaro Herrera <alvherre(at)alvh(dot)no-ip(dot)org> |
---|---|
To: | pgsql-committers(at)postgresql(dot)org |
Subject: | pgsql: Add geometry/range functions to support BRIN inclusion |
Date: | 2015-05-05 18:25:27 |
Message-ID: | E1YphX5-0005Dk-05@gemulon.postgresql.org |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-committers |
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
Branch
------
master
Details
-------
http://git.postgresql.org/pg/commitdiff/3b6db1f445e14bd189ebc99ce1e5535a1c624613
Modified Files
--------------
doc/src/sgml/func.sgml | 47 ++++++++++++++++++++++++++
src/backend/utils/adt/geo_ops.c | 39 +++++++++++++++++++++
src/backend/utils/adt/network.c | 52 ++++++++++++++++++++++++++++
src/backend/utils/adt/rangetypes.c | 54 +++++++++++++++++++++++-------
src/include/catalog/catversion.h | 2 +-
src/include/catalog/pg_cast.h | 1 +
src/include/catalog/pg_proc.h | 10 ++++++
src/include/utils/builtins.h | 2 ++
src/include/utils/geo_decls.h | 2 ++
src/include/utils/rangetypes.h | 1 +
src/test/regress/expected/geometry.out | 34 +++++++++++++++++++
src/test/regress/expected/geometry_1.out | 34 +++++++++++++++++++
src/test/regress/expected/geometry_2.out | 34 +++++++++++++++++++
src/test/regress/expected/inet.out | 28 ++++++++++++++++
src/test/regress/expected/rangetypes.out | 20 ++++++++++-
src/test/regress/sql/geometry.sql | 6 ++++
src/test/regress/sql/inet.sql | 7 ++++
src/test/regress/sql/rangetypes.sql | 6 +++-
18 files changed, 363 insertions(+), 16 deletions(-)
From | Date | Subject | |
---|---|---|---|
Next Message | Peter Eisentraut | 2015-05-05 18:58:25 | pgsql: doc: Update installation instructions for new shared libperl/lib |
Previous Message | Alvaro Herrera | 2015-05-05 18:02:50 | Re: pgsql: Improve speed of make check-world |