diff options
Diffstat (limited to 'src/test/regress/sql/horology.sql')
| -rw-r--r-- | src/test/regress/sql/horology.sql | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/src/test/regress/sql/horology.sql b/src/test/regress/sql/horology.sql index 78091112ca..2724a2bbc7 100644 --- a/src/test/regress/sql/horology.sql +++ b/src/test/regress/sql/horology.sql @@ -307,6 +307,34 @@ SELECT '2020-10-05'::timestamptz >= '4714-11-24 BC'::timestamp as t; RESET TimeZone; -- +-- Tests for BETWEEN +-- + +explain (costs off) +select count(*) from date_tbl + where f1 between '1997-01-01' and '1998-01-01'; +select count(*) from date_tbl + where f1 between '1997-01-01' and '1998-01-01'; + +explain (costs off) +select count(*) from date_tbl + where f1 not between '1997-01-01' and '1998-01-01'; +select count(*) from date_tbl + where f1 not between '1997-01-01' and '1998-01-01'; + +explain (costs off) +select count(*) from date_tbl + where f1 between symmetric '1997-01-01' and '1998-01-01'; +select count(*) from date_tbl + where f1 between symmetric '1997-01-01' and '1998-01-01'; + +explain (costs off) +select count(*) from date_tbl + where f1 not between symmetric '1997-01-01' and '1998-01-01'; +select count(*) from date_tbl + where f1 not between symmetric '1997-01-01' and '1998-01-01'; + +-- -- Formats -- |
