1
0
mirror of https://github.com/postgres/postgres.git synced 2025-07-26 01:22:12 +03:00
Files
config
contrib
adminpack
btree_gist
data
expected
bit.out
bytea.out
cash.out
char.out
cidr.out
date.out
float4.out
float8.out
inet.out
init.out
int2.out
int4.out
int8.out
interval.out
macaddr.out
numeric.out
oid.out
text.out
time.out
timestamp.out
timestamptz.out
timetz.out
varbit.out
varchar.out
sql
Makefile
README.btree_gist
btree_bit.c
btree_bytea.c
btree_cash.c
btree_date.c
btree_float4.c
btree_float8.c
btree_gist.c
btree_gist.h
btree_gist.sql.in
btree_inet.c
btree_int2.c
btree_int4.c
btree_int8.c
btree_interval.c
btree_macaddr.c
btree_numeric.c
btree_oid.c
btree_text.c
btree_time.c
btree_ts.c
btree_utils_num.c
btree_utils_num.h
btree_utils_var.c
btree_utils_var.h
uninstall_btree_gist.sql
chkpass
cube
dblink
earthdistance
fuzzystrmatch
hstore
intagg
intarray
isn
lo
ltree
oid2name
pg_buffercache
pg_freespacemap
pg_trgm
pgbench
pgcrypto
pgrowlocks
pgstattuple
seg
spi
sslinfo
start-scripts
tablefunc
tsearch2
vacuumlo
xml2
Makefile
README
contrib-global.mk
doc
src
COPYRIGHT
GNUmakefile.in
Makefile
README
README.CVS
aclocal.m4
configure
configure.in
postgres/contrib/btree_gist/expected/timestamp.out
Teodor Sigaev ef770cbb69 Fixes from Janko Richter <jankorichter@yahoo.de>
- Fix wrong index results on text, char, varchar for multibyte strings
- Fix some SIGFPE signals
- Add support for infinite timestamps
- Because of locale settings, btree_gist can not be a prefix index anymore (for text).
  Each node holds now just the lower and upper boundary.
2005-07-01 13:44:56 +00:00

67 lines
1.2 KiB
Plaintext

-- timestamp check
CREATE TABLE timestamptmp (a timestamp);
\copy timestamptmp from 'data/timestamp.data'
SET enable_seqscan=on;
SELECT count(*) FROM timestamptmp WHERE a < '2004-10-26 08:55:08';
count
-------
278
(1 row)
SELECT count(*) FROM timestamptmp WHERE a <= '2004-10-26 08:55:08';
count
-------
279
(1 row)
SELECT count(*) FROM timestamptmp WHERE a = '2004-10-26 08:55:08';
count
-------
1
(1 row)
SELECT count(*) FROM timestamptmp WHERE a >= '2004-10-26 08:55:08';
count
-------
290
(1 row)
SELECT count(*) FROM timestamptmp WHERE a > '2004-10-26 08:55:08';
count
-------
289
(1 row)
CREATE INDEX timestampidx ON timestamptmp USING gist ( a );
SET enable_seqscan=off;
SELECT count(*) FROM timestamptmp WHERE a < '2004-10-26 08:55:08'::timestamp;
count
-------
278
(1 row)
SELECT count(*) FROM timestamptmp WHERE a <= '2004-10-26 08:55:08'::timestamp;
count
-------
279
(1 row)
SELECT count(*) FROM timestamptmp WHERE a = '2004-10-26 08:55:08'::timestamp;
count
-------
1
(1 row)
SELECT count(*) FROM timestamptmp WHERE a >= '2004-10-26 08:55:08'::timestamp;
count
-------
290
(1 row)
SELECT count(*) FROM timestamptmp WHERE a > '2004-10-26 08:55:08'::timestamp;
count
-------
289
(1 row)