When I enter my explain SELECT statement at a mysql shell I get the following output:
+----+--------------------+-------+------+---------------+------+---------+----------------------------------+------+----------------------------------------------+
| id | select_type | table | type | possible_keys | key | key_len | ref | rows | Extra |
+----+--------------------+-------+------+---------------+------+---------+----------------------------------+------+----------------------------------------------+
| 1 | PRIMARY | main | ref | idx1 | idx1 | 52 | const,const | 1 | Using where; Using temporary; Using filesort |
Notice the multiple entries in the Extra column.
This is what I get when I enter the same statement in phpMyAdmin 3.3.5:
http://www.image-upload.net/images/wp8revfnn09x8egy873.png
View and moderate all "bugs Discussion" comments posted by this user
Mark all as spam, and block user from posting to "Bugs"
phpMyAdmin missing explain information
View and moderate all "bugs Discussion" comments posted by this user
Mark all as spam, and block user from posting to "Bugs"
View and moderate all "bugs Discussion" comments posted by this user
Mark all as spam, and block user from posting to "Bugs"
mysql complete explain information
Any update on this?
I need your input. In libraries/display_tbl.lib.php in the PMA_displayTableBody() function, you'll find this line:
while ($row = PMA_DBI_fetch_row($dt_result)) {
under it, add this:
echo '<pre>'; print_r($row); echo '</pre>';
and tell me the output.
Also, which version of these components are you using?
- MySQL server
- MySQL client (can be seen on phpMyAdmin's home page)
Hi there, thanks for taking time to investigate my issue!
Here are the versions I am using:
PhpMyAdmin 3.3.5
Server Version: 5.1.48-enterprise-gpl-advanced-log
MySQL-Client-Version: 5.1.36
PHP/5.3.2
and the SQL statement that is causing trouble:
mysql> explain SELECT main.`timestamp`, main.`value`, main.`bulk_type`, main.`counter_id` FROM `counter_bulk_data` main WHERE main. `counter_id` IN ('0000000000000' ) AND main.`bulk_type`= 'databasetbl' AND main.`timestamp` = (SELECT MAX(sub.`timestamp`) FROM `counter_bulk_data` sub WHERE main.`counter_id` = sub.`counter_id`) GROUP BY main.`counter_id`;
+----+--------------------+-------+------+---------------+------+---------+----------------------------------+------+----------------------------------------------+
| id | select_type | table | type | possible_keys | key | key_len | ref | rows | Extra |
+----+--------------------+-------+------+---------------+------+---------+----------------------------------+------+----------------------------------------------+
| 1 | PRIMARY | main | ref | idx1 | idx1 | 52 | const,const | 4614 | Using where; Using temporary; Using filesort |
| 2 | DEPENDENT SUBQUERY | sub | ref | idx1 | idx1 | 18 | database.main.counter_id | 6 | |
+----+--------------------+-------+------+---------------+------+---------+----------------------------------+------+----------------------------------------------+
2 rows in set (0.00 sec)
Here is the debug output you asked for:
Array
(
[0] => 1
[1] => PRIMARY
[2] => main
[3] => ref
[4] => idx1
[5] => idx1
[6] => 52
[7] => const,const
[8] => 1
[9] => Using where
)
Array
(
[0] => 2
[1] => DEPENDENT SUBQUERY
[2] => sub
[3] => ref
[4] => idx1
[5] => idx1
[6] => 18
[7] => database.main.counter_id
[8] => 73
[9] =>
)
and a screenshot of it:
http://www.image-upload.net/viewer.php?file=thpuhodl3qop26p2zuv.png
Another thing I found out is that a different SQL statement which also yields three entries in the Extra column gets displayed correctly on the same system:
mysql> explain SELECT * FROM `another_table` WHERE isFoobar = 'false' GROUP BY priority LIMIT 100;
+----+-------------+-------------------------+------+---------------+------+---------+------+-------+----------------------------------------------+
| id | select_type | table | type | possible_keys | key | key_len | ref | rows | Extra |
+----+-------------+-------------------------+------+---------------+------+---------+------+-------+----------------------------------------------+
| 1 | SIMPLE | commodule_config_change | ALL | NULL | NULL | NULL | NULL | 12808 | Using where; Using temporary; Using filesort |
+----+-------------+-------------------------+------+---------------+------+---------+------+-------+----------------------------------------------+
1 row in set (0.00 sec)
http://www.image-upload.net/viewer.php?file=bikf43k86cgdu5iplb7t.png
You should be using the mysqli extension, are you?
No, we don't use mysqli.
mysqli is recommended for MySQL 4.1 and later.
If you can attach here a small export so that I can reproduce this problem, I'll test it with mysqli.
We will try yo update to mysqli and test if that was the problem.
I'll report back.
This Tracker item was closed automatically by the system. It was
previously set to a Pending status, and the original submitter
did not respond within 14 days (the time period specified by
the administrator of this Tracker).