diff options
author | unknown <sanja@montyprogram.com> | 2012-05-22 08:48:10 +0300 |
---|---|---|
committer | unknown <sanja@montyprogram.com> | 2012-05-22 08:48:10 +0300 |
commit | 950abd526837b8772044d521387fa6d410de5706 (patch) | |
tree | d5deadcf46de5a138088ce2f2dd407dbba094a56 /sql/item_sum.cc | |
parent | 280fcf08085e43b5359ec79c0e34166e51b3ebd8 (diff) | |
download | mariadb-git-950abd526837b8772044d521387fa6d410de5706.tar.gz |
Fix of LP bug#992380 + revise fix_fields about missing with_subselect collection
The problem is that some fix_fields do not call Item_func::fix_fields and do not collect with subselect_information.
Diffstat (limited to 'sql/item_sum.cc')
-rw-r--r-- | sql/item_sum.cc | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/sql/item_sum.cc b/sql/item_sum.cc index ac6ddc0fd54..61a780b6222 100644 --- a/sql/item_sum.cc +++ b/sql/item_sum.cc @@ -574,6 +574,7 @@ Item_sum_num::fix_fields(THD *thd, Item **ref) if (args[i]->fix_fields(thd, args + i) || args[i]->check_cols(1)) return TRUE; set_if_bigger(decimals, args[i]->decimals); + with_subselect|= args[i]->with_subselect; } result_field=0; max_length=float_length(decimals); @@ -604,6 +605,7 @@ Item_sum_hybrid::fix_fields(THD *thd, Item **ref) (item= args[0])->check_cols(1)) return TRUE; decimals=item->decimals; + with_subselect= args[0]->with_subselect; switch (hybrid_type= item->result_type()) { case INT_RESULT: @@ -3216,6 +3218,7 @@ Item_func_group_concat::fix_fields(THD *thd, Item **ref) args[i]->fix_fields(thd, args + i)) || args[i]->check_cols(1)) return TRUE; + with_subselect|= args[i]->with_subselect; } if (agg_item_charsets(collation, func_name(), |