summaryrefslogtreecommitdiff
path: root/mysql-test
diff options
context:
space:
mode:
authorserg@serg.mylan <>2004-03-23 14:43:24 +0100
committerserg@serg.mylan <>2004-03-23 14:43:24 +0100
commit99886df867b34cb8310e02b6a833ee58045d3e96 (patch)
tree303d154fcdcdeb732e85c89c418f9b45836d801e /mysql-test
parent6158c94b3275b496557d6525a0a8dcd6b4575a88 (diff)
downloadmariadb-git-99886df867b34cb8310e02b6a833ee58045d3e96.tar.gz
correct support for a mix of UNION/UNION ALL in the same query.
Bug#1428
Diffstat (limited to 'mysql-test')
-rw-r--r--mysql-test/r/union.result10
-rw-r--r--mysql-test/t/union.test3
2 files changed, 7 insertions, 6 deletions
diff --git a/mysql-test/r/union.result b/mysql-test/r/union.result
index 5eb447ab223..c00b2732bd1 100644
--- a/mysql-test/r/union.result
+++ b/mysql-test/r/union.result
@@ -36,8 +36,6 @@ a b
1 a
2 b
3 c
-3 c
-3 c
4 d
5 f
6 e
@@ -48,8 +46,6 @@ select 0,'#' union select a,b from t1 union all select a,b from t2 union select
1 a
2 b
3 c
-3 c
-3 c
4 d
5 f
6 e
@@ -920,5 +916,9 @@ select * from t1 UNION select * from t1 UNION ALL select * from t1;
i
1
1
-1
drop table t1;
+select 1 as a union all select 1 union all select 2 union select 1 union all select 2;
+a
+1
+2
+2
diff --git a/mysql-test/t/union.test b/mysql-test/t/union.test
index 06110474992..b744610ce3d 100644
--- a/mysql-test/t/union.test
+++ b/mysql-test/t/union.test
@@ -493,6 +493,7 @@ create table t1 (i int);
insert into t1 values (1);
select * from t1 UNION select * from t1;
select * from t1 UNION ALL select * from t1;
-# The following should return 2 lines
select * from t1 UNION select * from t1 UNION ALL select * from t1;
drop table t1;
+select 1 as a union all select 1 union all select 2 union select 1 union all select 2;
+