diff options
author | unknown <bell@sanja.is.com.ua> | 2002-11-29 10:44:30 +0200 |
---|---|---|
committer | unknown <bell@sanja.is.com.ua> | 2002-11-29 10:44:30 +0200 |
commit | 5b62dfcdf51a695ebc724cb453919eb909ca274f (patch) | |
tree | f5b26feb2914ecd10b0bde1eb6e509b1da74c311 /mysql-test | |
parent | 781a5bc81ad3fdd6111986a895e6025d6910773e (diff) | |
download | mariadb-git-5b62dfcdf51a695ebc724cb453919eb909ca274f.tar.gz |
fixed error handling bug
fixed naming bug
fixed bug of subselect excluding
mysql-test/r/subselect.result:
test of error handling bug
test of naming bug
test bug of subselect excluding
mysql-test/t/subselect.test:
test of error handling bug
test of naming bug
test bug of subselect excluding
sql/item_subselect.cc:
fixed naming bug
fixed error handling bug
sql/sql_lex.cc:
fixed subselect excluding bug
Diffstat (limited to 'mysql-test')
-rw-r--r-- | mysql-test/r/subselect.result | 8 | ||||
-rw-r--r-- | mysql-test/t/subselect.test | 4 |
2 files changed, 12 insertions, 0 deletions
diff --git a/mysql-test/r/subselect.result b/mysql-test/r/subselect.result index 523c3af91c4..bbf70150ee0 100644 --- a/mysql-test/r/subselect.result +++ b/mysql-test/r/subselect.result @@ -35,6 +35,14 @@ Unknown column 'a' in 'field list' SELECT * FROM (SELECT 1 as id) WHERE id IN (SELECT * FROM (SELECT 1 as id) ORDER BY id LIMIT 1); id 1 +SELECT * FROM (SELECT 1) WHERE 1 IN (SELECT 1,1); +Cardinality error (more/less than 1 columns) +SELECT 1 IN (SELECT 1); +1 IN (SELECT 1) +1 +SELECT 1 FROM (SELECT 1 as a) WHERE 1 IN (SELECT (SELECT a)); +1 +1 drop table if exists t1,t2,t3,t4,t5,t6,t7,t8; create table t1 (a int); create table t2 (a int, b int); diff --git a/mysql-test/t/subselect.test b/mysql-test/t/subselect.test index 17f3008b62e..c875f8372b3 100644 --- a/mysql-test/t/subselect.test +++ b/mysql-test/t/subselect.test @@ -16,6 +16,10 @@ SELECT 1 as a FROM (SELECT 1) HAVING (SELECT a)=1; -- error 1054 SELECT 1 FROM (SELECT (SELECT a)); SELECT * FROM (SELECT 1 as id) WHERE id IN (SELECT * FROM (SELECT 1 as id) ORDER BY id LIMIT 1); +-- error 1239 +SELECT * FROM (SELECT 1) WHERE 1 IN (SELECT 1,1); +SELECT 1 IN (SELECT 1); +SELECT 1 FROM (SELECT 1 as a) WHERE 1 IN (SELECT (SELECT a)); drop table if exists t1,t2,t3,t4,t5,t6,t7,t8; create table t1 (a int); |