mirror of
https://github.com/MariaDB/server.git
synced 2025-08-08 11:22:35 +03:00
MDEV-10729: Server crashes in st_select_lex::set_explain_type
Make the new (CTE-related) code in set_explain_type to take into account that some JOIN_TABs are non-merged semi-joins, and do not have a TABLE object.
This commit is contained in:
@@ -4370,7 +4370,7 @@ void st_select_lex::set_explain_type(bool on_the_fly)
|
||||
for (JOIN_TAB *tab= first_explain_order_tab(join); tab;
|
||||
tab= next_explain_order_tab(join, tab))
|
||||
{
|
||||
if (tab->table->pos_in_table_list->with)
|
||||
if (tab->table && tab->table->pos_in_table_list->with)
|
||||
{
|
||||
uses_cte= true;
|
||||
break;
|
||||
|
Reference in New Issue
Block a user