summaryrefslogtreecommitdiff
path: root/sql/item_cmpfunc.h
diff options
context:
space:
mode:
authorunknown <timour@askmonty.org>2010-09-16 16:49:20 +0300
committerunknown <timour@askmonty.org>2010-09-16 16:49:20 +0300
commit35f0faf4c7cd5d0b6270855f274027f85c5aca72 (patch)
tree7375b4789aaa50fcaf351de41f224aa229bb75a2 /sql/item_cmpfunc.h
parent22a2cce37790fbbd7f847407013ce15d7aa8ed86 (diff)
downloadmariadb-git-35f0faf4c7cd5d0b6270855f274027f85c5aca72.tar.gz
MWL#89: Cost-based choice between Materialization and IN->EXISTS transformation
- Corrected a wrong result that was recorded by the MySQL fix for BUG#39069. - Removed Item_func_isnull::cached_value and all the logic around this custom-made caching of the NULL result because MWL#89 optimizes subqueries before the outer query is being executed, and this cache cannot be made easily to work for all kinds of Items (specifically Item_sum_sum, but others too).
Diffstat (limited to 'sql/item_cmpfunc.h')
-rw-r--r--sql/item_cmpfunc.h11
1 files changed, 0 insertions, 11 deletions
diff --git a/sql/item_cmpfunc.h b/sql/item_cmpfunc.h
index e161c1baa84..33407a161b8 100644
--- a/sql/item_cmpfunc.h
+++ b/sql/item_cmpfunc.h
@@ -1304,8 +1304,6 @@ public:
class Item_func_isnull :public Item_bool_func
{
-protected:
- longlong cached_value;
public:
Item_func_isnull(Item *a) :Item_bool_func(a) {}
longlong val_int();
@@ -1323,18 +1321,9 @@ public:
{
used_tables_cache= 0; /* is always false */
const_item_cache= 1;
- cached_value= (longlong) 0;
}
else
- {
args[0]->update_used_tables();
- if ((const_item_cache= !(used_tables_cache= args[0]->used_tables())) &&
- !with_subselect)
- {
- /* Remember if the value is always NULL or never NULL */
- cached_value= (longlong) args[0]->is_null();
- }
- }
}
table_map not_null_tables() const { return 0; }
optimize_type select_optimize() const { return OPTIMIZE_NULL; }