1
0
mirror of https://github.com/postgres/postgres.git synced 2025-08-14 02:22:38 +03:00
Files
config
contrib
adminpack
auth_delay
auto_explain
bloom
btree_gin
expected
sql
bit.sql
bytea.sql
char.sql
cidr.sql
date.sql
float4.sql
float8.sql
inet.sql
install_btree_gin.sql
int2.sql
int4.sql
int8.sql
interval.sql
macaddr.sql
money.sql
numeric.sql
oid.sql
text.sql
time.sql
timestamp.sql
timestamptz.sql
timetz.sql
varbit.sql
varchar.sql
.gitignore
Makefile
btree_gin--1.0.sql
btree_gin--unpackaged--1.0.sql
btree_gin.c
btree_gin.control
btree_gist
chkpass
citext
cube
dblink
dict_int
dict_xsyn
earthdistance
file_fdw
fuzzystrmatch
hstore
hstore_plperl
hstore_plpython
intagg
intarray
isn
lo
ltree
ltree_plpython
oid2name
pageinspect
passwordcheck
pg_buffercache
pg_freespacemap
pg_prewarm
pg_standby
pg_stat_statements
pg_trgm
pg_visibility
pgcrypto
pgrowlocks
pgstattuple
postgres_fdw
seg
sepgsql
spi
sslinfo
start-scripts
tablefunc
tcn
test_decoding
tsearch2
tsm_system_rows
tsm_system_time
unaccent
uuid-ossp
vacuumlo
xml2
Makefile
README
contrib-global.mk
doc
src
.dir-locals.el
.gitattributes
.gitignore
COPYRIGHT
GNUmakefile.in
HISTORY
Makefile
README
README.git
aclocal.m4
configure
configure.in
postgres/contrib/btree_gin/sql/bit.sql
Tom Lane 9151e1bb06 Add btree_gin contrib module.
Teodor Sigaev and Oleg Bartunov
2009-03-25 23:20:01 +00:00

16 lines
477 B
SQL

set enable_seqscan=off;
CREATE TABLE test_bit (
i bit(3)
);
INSERT INTO test_bit VALUES ('001'),('010'),('011'),('100'),('101'),('110');
CREATE INDEX idx_bit ON test_bit USING gin (i);
SELECT * FROM test_bit WHERE i<'100'::bit(3) ORDER BY i;
SELECT * FROM test_bit WHERE i<='100'::bit(3) ORDER BY i;
SELECT * FROM test_bit WHERE i='100'::bit(3) ORDER BY i;
SELECT * FROM test_bit WHERE i>='100'::bit(3) ORDER BY i;
SELECT * FROM test_bit WHERE i>'100'::bit(3) ORDER BY i;