datatype in test, to try to avoid any dependency on local time zone.
\set ECHO none
create table inttmp (b int4);
\copy inttmp from 'data/test_btree.data'
-create table tstmp ( t datetime );
+create table tstmp ( t timestamp without time zone );
\copy tstmp from 'data/test_btree_ts.data'
-- without idx
select count(*) from inttmp where b <=10;
11
(1 row)
-select count(*) from tstmp where t < '2001-05-29 08:33:09+04';
+select count(*) from tstmp where t < '2001-05-29 08:33:09';
count
-------
- 7
+ 66
(1 row)
-- create idx
11
(1 row)
-select count(*) from tstmp where t < '2001-05-29 08:33:09+04';
+select count(*) from tstmp where t < '2001-05-29 08:33:09';
count
-------
- 7
+ 66
(1 row)
\copy inttmp from 'data/test_btree.data'
-create table tstmp ( t datetime );
+create table tstmp ( t timestamp without time zone );
\copy tstmp from 'data/test_btree_ts.data'
select count(*) from inttmp where b <=10;
-select count(*) from tstmp where t < '2001-05-29 08:33:09+04';
+select count(*) from tstmp where t < '2001-05-29 08:33:09';
-- create idx
select count(*) from inttmp where b <=10;
-select count(*) from tstmp where t < '2001-05-29 08:33:09+04';
+select count(*) from tstmp where t < '2001-05-29 08:33:09';