mirror of
https://github.com/MariaDB/server.git
synced 2025-08-31 22:22:30 +03:00
Fixed bug #5500: EXPLAIN returned a wrong select_type for queries using views.
Select_type in the EXPLAIN output for the query SELECT * FROM t1 was 'SIMPLE', while for the query SELECT * FROM v1, where the view v1 was defined as SELECT * FROM t1, the EXPLAIN output contained 'PRIMARY' for the select_type column.
This commit is contained in:
@@ -807,8 +807,8 @@ explain
|
||||
SELECT straight_join sql_no_cache v1.a, v1.b, v1.real_b from t2, v1
|
||||
where t2.b=v1.a GROUP BY t2.b;
|
||||
id select_type table type possible_keys key key_len ref rows Extra
|
||||
1 PRIMARY t2 index b b 2 NULL 10 Using index
|
||||
1 PRIMARY t1 eq_ref PRIMARY PRIMARY 1 test.t2.b 1
|
||||
1 SIMPLE t2 index b b 2 NULL 10 Using index
|
||||
1 SIMPLE t1 eq_ref PRIMARY PRIMARY 1 test.t2.b 1
|
||||
SELECT straight_join sql_no_cache v1.a, v1.b, v1.real_b from t2, v1
|
||||
where t2.b=v1.a GROUP BY t2.b;
|
||||
a b real_b
|
||||
|
Reference in New Issue
Block a user