summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTom Lane2003-11-02 22:35:26 +0000
committerTom Lane2003-11-02 22:35:26 +0000
commitb402503fb6c1455536dc2940d8cb50b68a5e8b17 (patch)
treed21146514ef2a8b7ac62b5c1b33de2334fd4e513
parenteeaf5f04ae3fca446b43851fb9a612fe0c980994 (diff)
Adjust data types in some of the UNION tests to avoid potentially
platform-dependent results, as per example from Larry Rosenman.
-rw-r--r--src/test/regress/expected/union.out8
-rw-r--r--src/test/regress/sql/union.sql6
2 files changed, 7 insertions, 7 deletions
diff --git a/src/test/regress/expected/union.out b/src/test/regress/expected/union.out
index b2b94a7894e..d09d9a81647 100644
--- a/src/test/regress/expected/union.out
+++ b/src/test/regress/expected/union.out
@@ -74,7 +74,7 @@ SELECT 1 AS two UNION SELECT 2.2;
2.2
(2 rows)
-SELECT 1 AS one UNION SELECT 1.0;
+SELECT 1 AS one UNION SELECT 1.0::float8;
one
-----
1
@@ -87,10 +87,10 @@ SELECT 1.1 AS two UNION ALL SELECT 2;
2
(2 rows)
-SELECT 1.0 AS two UNION ALL SELECT 1;
+SELECT 1.0::float8 AS two UNION ALL SELECT 1;
two
-----
- 1.0
+ 1
1
(2 rows)
@@ -102,7 +102,7 @@ SELECT 1.1 AS three UNION SELECT 2 UNION SELECT 3;
3
(3 rows)
-SELECT 1.1 AS two UNION SELECT 2 UNION SELECT 2.0;
+SELECT 1.1::float8 AS two UNION SELECT 2 UNION SELECT 2.0::float8;
two
-----
1.1
diff --git a/src/test/regress/sql/union.sql b/src/test/regress/sql/union.sql
index c69e4c3f152..0f846091cd1 100644
--- a/src/test/regress/sql/union.sql
+++ b/src/test/regress/sql/union.sql
@@ -26,15 +26,15 @@ SELECT 1.1 AS two UNION SELECT 2;
SELECT 1 AS two UNION SELECT 2.2;
-SELECT 1 AS one UNION SELECT 1.0;
+SELECT 1 AS one UNION SELECT 1.0::float8;
SELECT 1.1 AS two UNION ALL SELECT 2;
-SELECT 1.0 AS two UNION ALL SELECT 1;
+SELECT 1.0::float8 AS two UNION ALL SELECT 1;
SELECT 1.1 AS three UNION SELECT 2 UNION SELECT 3;
-SELECT 1.1 AS two UNION SELECT 2 UNION SELECT 2.0;
+SELECT 1.1::float8 AS two UNION SELECT 2 UNION SELECT 2.0::float8;
SELECT 1.1 AS three UNION SELECT 2 UNION ALL SELECT 2;