[MDEV-5118] Explain output for SHOW EXPLAIN in the slow log looks useless Created: 2013-10-09  Updated: 2023-11-28

Status: Open
Project: MariaDB Server
Component/s: Optimizer
Affects Version/s: 10.0.10, 10.3, 10.4, 10.5, 10.6, 10.7, 10.8, 10.9, 10.10
Fix Version/s: 10.4, 10.5, 10.6

Type: Bug Priority: Trivial
Reporter: Elena Stepanova Assignee: Sergei Petrunia
Resolution: Unresolved Votes: 0
Labels: None

Issue Links:
Relates
relates to MDEV-407 Print EXPLAIN [ANALYZE] in the slow q... Closed

 Description   

In all attempts, I was never able to get any other "plan" than this for SHOW EXPLAIN in the slow log:

# Time: 131009 20:35:29
# User@Host: root[root] @ localhost [127.0.0.1]
# Thread_id: 6  Schema: test  QC_hit: No
# Query_time: 0.002340  Lock_time: 0.000849  Rows_sent: 1  Rows_examined: 1
#
#  id   select_type     table   type    possible_keys   key     key_len ref     rows    Extra
#  1    SIMPLE  EXPLAIN ALL     NULL    NULL    NULL    NULL    NULL    
#
SET timestamp=1381336529;
show explain for 4;

If it's really going to be always the same, maybe it doesn't make sense to print it there at all.



 Comments   
Comment by Sergei Petrunia [ 2013-10-11 ]

I suspect this is because they've made me to re-implement SHOW EXPLAIN as a SELECT from an I_S table.

There can be other kinds statements that do not really have query plans. Perhaps, log_slow_verbosity=explain should not print EXPLAINs that are trivial.

Generated at Thu Feb 08 07:01:49 UTC 2024 using Jira 8.20.16#820016-sha1:9d11dbea5f4be3d4cc21f03a88dd11d8c8687422.