diff options
Diffstat (limited to 'mysql-test/t/union.test')
-rw-r--r-- | mysql-test/t/union.test | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/mysql-test/t/union.test b/mysql-test/t/union.test index be6bc7a48d8..5ff22f1d6b6 100644 --- a/mysql-test/t/union.test +++ b/mysql-test/t/union.test @@ -717,3 +717,15 @@ union order by sdate; show columns from t4; drop table t1, t2, t3, t4; + +# +# Bug #2435 UNION with parentheses not supported +# +create table t1 (a int not null, b char (10) not null); +insert into t1 values(1,'a'),(2,'b'),(3,'c'),(3,'c'); +select * from ((select * from t1 limit 1)) a; +select * from ((select * from t1 limit 1) union (select * from t1 limit 1)) a; +select * from ((select * from t1 limit 1) union (select * from t1 limit 1) union (select * from t1 limit 1)) a; +select * from ((((select * from t1))) union (select * from t1) union (select * from t1)) a; +select * from ((select * from t1) union (((select * from t1))) union (select * from t1)) a; +drop table t1; |