summaryrefslogtreecommitdiff
path: root/sql/item_cmpfunc.cc
diff options
context:
space:
mode:
authorMarko Mäkelä <marko.makela@mariadb.com>2019-03-08 11:19:48 +0200
committerMarko Mäkelä <marko.makela@mariadb.com>2019-03-08 11:19:48 +0200
commitc67b306e4f90788b979bf85f5a2ab282798fc897 (patch)
treeb7fa51ab7bacbf5ed8c20367f009625a7da0f95b /sql/item_cmpfunc.cc
parent91d7e7b244be2ebf39eb135bacea99ed19657475 (diff)
parent94eb56fb29334a1075103becb625685b23f7d437 (diff)
downloadmariadb-git-c67b306e4f90788b979bf85f5a2ab282798fc897.tar.gz
Merge 10.3 into 10.4
Diffstat (limited to 'sql/item_cmpfunc.cc')
-rw-r--r--sql/item_cmpfunc.cc17
1 files changed, 17 insertions, 0 deletions
diff --git a/sql/item_cmpfunc.cc b/sql/item_cmpfunc.cc
index ffb7b60e4de..86725de8ae7 100644
--- a/sql/item_cmpfunc.cc
+++ b/sql/item_cmpfunc.cc
@@ -5209,6 +5209,23 @@ Item *Item_cond::build_clone(THD *thd)
}
+bool Item_cond::excl_dep_on_table(table_map tab_map)
+{
+ if (used_tables() & OUTER_REF_TABLE_BIT)
+ return false;
+ if (!(used_tables() & ~tab_map))
+ return true;
+ List_iterator_fast<Item> li(list);
+ Item *item;
+ while ((item= li++))
+ {
+ if (!item->excl_dep_on_table(tab_map))
+ return false;
+ }
+ return true;
+}
+
+
bool Item_cond::excl_dep_on_grouping_fields(st_select_lex *sel)
{
List_iterator_fast<Item> li(list);