diff options
author | unknown <timour@mysql.com> | 2004-11-09 17:56:33 +0200 |
---|---|---|
committer | unknown <timour@mysql.com> | 2004-11-09 17:56:33 +0200 |
commit | afbb5d8fac43708862b32f02c9cf82db1650eed7 (patch) | |
tree | b26854415da4cc507b7650b6dafa2faf1e6dbaad /mysql-test/r/having.result | |
parent | 47a96b3195b3f893207c0ba5c7f3600e5d95cf56 (diff) | |
download | mariadb-git-afbb5d8fac43708862b32f02c9cf82db1650eed7.tar.gz |
WL#1972 "Evaluate HAVING before SELECT select-list"
- post-review fix regarding Item_fields
- added test for the changed name resolution
mysql-test/r/having.result:
Test for changed name resolution of Item_fields
mysql-test/t/having.test:
Test for changed name resolution of Item_fields
sql/item.cc:
- Changed Item_field::fix_fields to perform the same name
resolution as Item_ref::fix_fields because column references
of subqueries inside HAVING may be represented as Item_fields,
and they need to be resolved as Item_refs.
- Adjusted Item_field::fix_fields so that it has the same variable
names and structure as Item_ref::fix_fields.
Diffstat (limited to 'mysql-test/r/having.result')
-rw-r--r-- | mysql-test/r/having.result | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/mysql-test/r/having.result b/mysql-test/r/having.result index 6f548d20668..86c9adf8cf6 100644 --- a/mysql-test/r/having.result +++ b/mysql-test/r/having.result @@ -245,6 +245,13 @@ col1 10 10 10 +select sum(col1) from t1 +group by col_t1 +having (select col_t1 from t2 where col_t1 = col_t2 order by col_t2 limit 1); +sum(col1) +40 +20 +30 select t1.col1 from t1 where t1.col2 in (select t2.col2 from t2 |