From d04c8ed9044eccebce043143a930617e3998c005 Mon Sep 17 00:00:00 2001 From: Heikki Linnakangas Date: Thu, 26 Mar 2015 19:12:00 +0200 Subject: Add support for index-only scans in GiST. This adds a new GiST opclass method, 'fetch', which is used to reconstruct the original Datum from the value stored in the index. Also, the 'canreturn' index AM interface function gains a new 'attno' argument. That makes it possible to use index-only scans on a multi-column index where some of the opclasses support index-only scans but some do not. This patch adds support in the box and point opclasses. Other opclasses can added later as follow-on patches (btree_gist would be particularly interesting). Anastasia Lubennikova, with additional fixes and modifications by me. --- src/include/access/gist.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src/include/access/gist.h') diff --git a/src/include/access/gist.h b/src/include/access/gist.h index 01f0a70feee..50261b8bdd5 100644 --- a/src/include/access/gist.h +++ b/src/include/access/gist.h @@ -33,7 +33,8 @@ #define GIST_PICKSPLIT_PROC 6 #define GIST_EQUAL_PROC 7 #define GIST_DISTANCE_PROC 8 -#define GISTNProcs 8 +#define GIST_FETCH_PROC 9 +#define GISTNProcs 9 /* * strategy numbers for GiST opclasses that want to implement the old -- cgit v1.2.3