{"id":3035,"date":"2016-03-04T21:42:44","date_gmt":"2016-03-04T21:42:44","guid":{"rendered":"https:\/\/qbytes.cloud\/?p=3035"},"modified":"2016-03-04T21:42:44","modified_gmt":"2016-03-04T21:42:44","slug":"explain-mysql-statement","status":"publish","type":"post","link":"https:\/\/www.qbytes.cloud\/index.php\/2016\/03\/04\/explain-mysql-statement\/","title":{"rendered":"Explain mysql statement"},"content":{"rendered":"<pre class=\"brush: bash; title: ; notranslate\" title=\"\">\n# mysql -u root -p \n<\/pre>\n<pre class=\"brush: bash; title: ; notranslate\" title=\"\">\nMariaDB &#x5B;(none)]&gt; wp_database -e &quot;EXPLAIN SELECT * FROM posts&quot;\n<\/pre>\n<pre class=\"brush: bash; title: ; notranslate\" title=\"\">\n EXPLAIN SELECT * FROM 2qGr3sjm_posts;\n+------+-------------+----------------+------+---------------+------+---------+------+------+-------+\n| id   | select_type | table          | type | possible_keys | key  | key_len | ref  | rows | Extra |\n+------+-------------+----------------+------+---------------+------+---------+------+------+-------+\n|    1 | SIMPLE      |          posts | ALL  | NULL          | NULL | NULL    | NULL | 2519 |       |\n+------+-------------+----------------+------+---------------+------+---------+------+------+-------+\n\n<\/pre>\n<p>Or from command line<\/p>\n<pre class=\"brush: bash; title: ; notranslate\" title=\"\">\n#  mysql -u root -p wp_database -e &quot;EXPLAIN SELECT * FROM posts&quot;\n<\/pre>\n","protected":false},"excerpt":{"rendered":"<p># mysql -u root -p MariaDB &#x5B;(none)]&gt; wp_database -e &quot;EXPLAIN SELECT * FROM posts&quot; EXPLAIN SELECT * FROM 2qGr3sjm_posts; +&#8212;&#8212;+&#8212;&#8212;&#8212;&#8212;-+&#8212;&#8212;&#8212;&#8212;&#8212;-+&#8212;&#8212;+&#8212;&#8212;&#8212;&#8212;&#8212;+&#8212;&#8212;+&#8212;&#8212;&#8212;+&#8212;&#8212;+&#8212;&#8212;+&#8212;&#8212;-+ | id | select_type | table | type | possible_keys | key | key_len | ref | rows | Extra | +&#8212;&#8212;+&#8212;&#8212;&#8212;&#8212;-+&#8212;&#8212;&#8212;&#8212;&#8212;-+&#8212;&#8212;+&#8212;&#8212;&#8212;&#8212;&#8212;+&#8212;&#8212;+&#8212;&#8212;&#8212;+&#8212;&#8212;+&#8212;&#8212;+&#8212;&#8212;-+ | 1 | SIMPLE | posts | ALL | NULL | NULL | &#8230; <a title=\"Explain mysql statement\" class=\"read-more\" href=\"https:\/\/www.qbytes.cloud\/index.php\/2016\/03\/04\/explain-mysql-statement\/\" aria-label=\"Read more about Explain mysql statement\">Read more<\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[70],"tags":[],"class_list":["post-3035","post","type-post","status-publish","format-standard","hentry","category-mysql"],"_links":{"self":[{"href":"https:\/\/www.qbytes.cloud\/index.php\/wp-json\/wp\/v2\/posts\/3035","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.qbytes.cloud\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.qbytes.cloud\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.qbytes.cloud\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.qbytes.cloud\/index.php\/wp-json\/wp\/v2\/comments?post=3035"}],"version-history":[{"count":0,"href":"https:\/\/www.qbytes.cloud\/index.php\/wp-json\/wp\/v2\/posts\/3035\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.qbytes.cloud\/index.php\/wp-json\/wp\/v2\/media?parent=3035"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.qbytes.cloud\/index.php\/wp-json\/wp\/v2\/categories?post=3035"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.qbytes.cloud\/index.php\/wp-json\/wp\/v2\/tags?post=3035"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}