diff options
Diffstat (limited to 'mysql-test/r/derived.result')
-rw-r--r-- | mysql-test/r/derived.result | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/mysql-test/r/derived.result b/mysql-test/r/derived.result index d3fbd557156..b99664835a2 100644 --- a/mysql-test/r/derived.result +++ b/mysql-test/r/derived.result @@ -17,6 +17,19 @@ select t1.a,t4.y from t1,(select t2.a as y from t2,(select t3.b from t3 where t3 a y 3 3 3 3 +SELECT a FROM (SELECT 1 FROM (SELECT 1) HAVING a=1); +Unknown column 'a' in 'having clause' +SELECT a,b as a FROM (SELECT '1' as a,'2' as b) HAVING a=1; +Column: 'a' in having clause is ambiguous +SELECT a,2 as a FROM (SELECT '1' as a) HAVING a=2; +a a +1 2 +SELECT a,2 as a FROM (SELECT '1' as a) HAVING a=1; +a a +SELECT 1 FROM (SELECT 1) WHERE a=2; +Unknown column 'a' in 'where clause' +SELECT (SELECT 1) as a FROM (SELECT 1 FROM t1 HAVING a=1); +Unknown column 'a' in 'having clause' drop table if exists t1.t2,t3; select * from (select 1); 1 |