git.postgresql.org Git - postgresql.git/commit

git projects / postgresql.git / commit
? search:
summary | shortlog | log | commit | commitdiff | tree
(parent: 896537f) | patch
Allow no-op GiST support functions to be omitted.
2017年9月20日 03:32:27 +0000 (23:32 -0400)
2017年9月20日 03:32:59 +0000 (23:32 -0400)
commit d3a4f89d8a3e500bd7c0b7a8a8a5ce1b47859128
Allow no-op GiST support functions to be omitted.

There are common use-cases in which the compress and/or decompress
functions can be omitted, with the result being that we make no
data transformation when storing or retrieving index values.
Previously, you had to provide a no-op function anyway, but this
patch allows such opclass support functions to be omitted.

Furthermore, if the compress function is omitted, then the core code
knows that the stored representation is the same as the original data.
This means we can allow index-only scans without requiring a fetch
function to be provided either. Previously you had to provide a
no-op fetch function if you wanted IOS to work.

This reportedly provides a small performance benefit in such cases,
but IMO the real reason for doing it is just to reduce the amount of
useless boilerplate code that has to be written for GiST opclasses.

Andrey Borodin, reviewed by Dmitriy Sarafannikov

Discussion: https://postgr.es/m/CAJEAwVELVx9gYscpE=Be6iJxvdW5unZ_LkcAaVNSeOwvdwtD=A@mail.gmail.com
doc/src/sgml/gist.sgml diff | blob | blame | history
src/backend/access/gist/gist.c diff | blob | blame | history
src/backend/access/gist/gistget.c diff | blob | blame | history
src/backend/access/gist/gistutil.c diff | blob | blame | history
src/backend/access/gist/gistvalidate.c diff | blob | blame | history
This is the main PostgreSQL git repository.
RSS Atom

AltStyle によって変換されたページ (->オリジナル) /