diff options
author | unknown <bell@sanja.is.com.ua> | 2004-09-16 16:24:46 +0300 |
---|---|---|
committer | unknown <bell@sanja.is.com.ua> | 2004-09-16 16:24:46 +0300 |
commit | 3b4c38336d554ecddec1ad41f60c50fff15a702d (patch) | |
tree | 23a14c8221f0e0a31e95198595c363f3d0ec588b /sql/item.cc | |
parent | 06b8f83f46667d4a1be23804bc982f3f5947397f (diff) | |
parent | 77ee831d3d9230912136d7b91f027f48df84431a (diff) | |
download | mariadb-git-3b4c38336d554ecddec1ad41f60c50fff15a702d.tar.gz |
Merge sanja.is.com.ua:/home/bell/mysql/bk/mysql-4.1
into sanja.is.com.ua:/home/bell/mysql/bk/work-sum-4.1
sql/item.cc:
Auto merged
sql/sql_base.cc:
Auto merged
sql/sql_select.cc:
Auto merged
Diffstat (limited to 'sql/item.cc')
-rw-r--r-- | sql/item.cc | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/sql/item.cc b/sql/item.cc index 1e090333bf4..8233d050783 100644 --- a/sql/item.cc +++ b/sql/item.cc @@ -1271,11 +1271,10 @@ bool Item_field::fix_fields(THD *thd, TABLE_LIST *tables, Item **ref) prev_subselect_item->parsing_place; /* check table fields only if subquery used somewhere out of HAVING - or SELECT list or outer SELECT do not use groupping (i.e. tables - are accessable) + or outer SELECT do not use groupping (i.e. tables are + accessable) */ - if (((place != IN_HAVING && - place != SELECT_LIST) || + if ((place != IN_HAVING || (sl->with_sum_func == 0 && sl->group_list.elements == 0)) && (tmp= find_field_in_tables(thd, this, table_list, &where, @@ -1954,8 +1953,7 @@ bool Item_ref::fix_fields(THD *thd,TABLE_LIST *tables, Item **reference) or SELECT list or outer SELECT do not use groupping (i.e. tables are accessable) */ - if (((place != IN_HAVING && - place != SELECT_LIST) || + if ((place != IN_HAVING || (sl->with_sum_func == 0 && sl->group_list.elements == 0)) && (tmp= find_field_in_tables(thd, this, table_list, &where, |