diff options
author | Igor Babaev <igor@askmonty.org> | 2016-11-13 14:46:33 -0800 |
---|---|---|
committer | Igor Babaev <igor@askmonty.org> | 2016-11-13 14:56:29 -0800 |
commit | 92bcb906a01515874eb3095eabfde7057f4f8d50 (patch) | |
tree | 4f124b2b4a93bf141534f25479d32875f1d139b8 /sql/sql_cte.cc | |
parent | f2219c8d3fb4a54da1fff74b8849c74b9a7de0c6 (diff) | |
download | mariadb-git-92bcb906a01515874eb3095eabfde7057f4f8d50.tar.gz |
Fixed bug mdev-11278.
If a recursive CTE referred to a materialized view/derived table then
the query that used this CTE returned a bogus error message.
Diffstat (limited to 'sql/sql_cte.cc')
-rw-r--r-- | sql/sql_cte.cc | 11 |
1 files changed, 0 insertions, 11 deletions
diff --git a/sql/sql_cte.cc b/sql/sql_cte.cc index 7e98a9bd1ff..a4ceae52e5e 100644 --- a/sql/sql_cte.cc +++ b/sql/sql_cte.cc @@ -1121,17 +1121,6 @@ bool With_element::check_unrestricted_recursive(st_select_lex *sel, { if(!tbl->is_with_table()) { - if (tbl->is_materialized_derived()) - { - table_map dep_map; - check_dependencies_in_unit(unit, NULL, false, &dep_map); - if (dep_map & get_elem_map()) - { - my_error(ER_REF_TO_RECURSIVE_WITH_TABLE_IN_DERIVED, - MYF(0), query_name->str); - return true; - } - } if (check_unrestricted_recursive(unit->first_select(), unrestricted, encountered)) |