btree_gin provides GIN operator classes that implement B-tree equivalent behavior for the data types
timestamp with time zone,
timestamp without time zone,
time with time zone,
time without time zone,
bpchar, and all
In general, these operator classes will not outperform the equivalent standard B-tree index methods, and they lack one major feature of the standard B-tree code: the ability to enforce uniqueness. However, they are useful for GIN testing and as a base for developing other GIN operator classes. Also, for queries that test both a GIN-indexable column and a B-tree-indexable column, it might be more efficient to create a multicolumn GIN index that uses one of these operator classes than to create two separate indexes that would have to be combined via bitmap ANDing.
This module is considered “trusted”, that is, it can be installed by non-superusers who have
CREATE privilege on the current database.
CREATE TABLE test (a int4); -- create index CREATE INDEX testidx ON test USING GIN (a); -- query SELECT * FROM test WHERE a < 10;
Teodor Sigaev (
<firstname.lastname@example.org>) and Oleg Bartunov (
<email@example.com>). See http://www.sai.msu.su/~megera/oddmuse/index.cgi/Gin for additional information.