diff options
author | Sergey Petrunya <psergey@askmonty.org> | 2012-05-16 20:22:54 +0400 |
---|---|---|
committer | Sergey Petrunya <psergey@askmonty.org> | 2012-05-16 20:22:54 +0400 |
commit | 483ae4bf81851a16e27cfc67b0eb474fed0a97dd (patch) | |
tree | ac57856c264be7bb9d4c9d89bf85ac1632c7a4f0 | |
parent | 533e1d28459ab5aa0604560bf8885ae18e553295 (diff) | |
download | mariadb-git-483ae4bf81851a16e27cfc67b0eb474fed0a97dd.tar.gz |
Make SHOW EXPLAIN give a separate timeout error.
-rw-r--r-- | sql/sql_show.cc | 15 |
1 files changed, 12 insertions, 3 deletions
diff --git a/sql/sql_show.cc b/sql/sql_show.cc index a0c39ff6c8c..2a9e5fa4954 100644 --- a/sql/sql_show.cc +++ b/sql/sql_show.cc @@ -2121,9 +2121,18 @@ void mysqld_show_explain(THD *thd, ulong thread_id) if (bres || explain_req.failed_to_produce) { /* TODO not enabled or time out */ - my_error(ER_ERROR_WHEN_EXECUTING_COMMAND, MYF(0), - "SHOW EXPLAIN", - "Target is not running EXPLAINable command"); + if (timed_out) + { + my_error(ER_ERROR_WHEN_EXECUTING_COMMAND, MYF(0), + "SHOW EXPLAIN", + "Timeout"); + } + else + { + my_error(ER_ERROR_WHEN_EXECUTING_COMMAND, MYF(0), + "SHOW EXPLAIN", + "Target is not running EXPLAINable command"); + } bres= TRUE; } else |