diff options
author | Sergey Petrunya <psergey@askmonty.org> | 2013-10-07 17:29:51 +0400 |
---|---|---|
committer | Sergey Petrunya <psergey@askmonty.org> | 2013-10-07 17:29:51 +0400 |
commit | 98a8642fe827fd9ac16bdfaf556599fa509d4180 (patch) | |
tree | 4215cf494f23de959522090ee386e125ba359308 /sql/sql_update.cc | |
parent | 69393db3d15b5eac143ab6068037f938b3003ce1 (diff) | |
download | mariadb-git-98a8642fe827fd9ac16bdfaf556599fa509d4180.tar.gz |
MDEV-3798: EXPLAIN UPDATE/DELETE
- Add support for EXPLAIN INSERT.
Diffstat (limited to 'sql/sql_update.cc')
-rw-r--r-- | sql/sql_update.cc | 17 |
1 files changed, 3 insertions, 14 deletions
diff --git a/sql/sql_update.cc b/sql/sql_update.cc index db32ad2a0c5..bc2c5c69adb 100644 --- a/sql/sql_update.cc +++ b/sql/sql_update.cc @@ -948,7 +948,7 @@ int mysql_update(THD *thd, if (!transactional_table && updated > 0) thd->transaction.stmt.modified_non_trans_table= TRUE; - thd->apc_target.disable(); //psergey-todo. + thd->apc_target.disable(); apc_target_enabled= false; end_read_record(&info); delete select; @@ -1035,19 +1035,8 @@ err: exit_without_my_ok: DBUG_ASSERT(!apc_target_enabled); query_plan.save_explain_data(thd->lex->explain); - - select_send *result; - if (!(result= new select_send())) - return 1; /* purecov: inspected */ - List<Item> dummy; /* note: looked in 5.6 and they too use a dummy list like this */ - result->prepare(dummy, &thd->lex->unit); - thd->send_explain_fields(result); - int err2= thd->lex->explain->print_explain(result, - thd->lex->describe); - if (err2) - result->abort_result_set(); - else - result->send_eof(); + + int err2= thd->lex->explain->send_explain(thd); delete select; free_underlaid_joins(thd, select_lex); |