November 2019
Beginner to intermediate
470 pages
11h 59m
English
The first transformation that the optimizer does is inline the views. Here's what happens:
SELECT * FROM ( SELECT * FROM a, b WHERE aid = bid) AS v, c WHERE v.aid = c.cid AND cid = 4;
The view is inlined and transformed into a subselect. What does this one buy us? Actually, nothing. All it does is open the door for further optimization, which will really be a game-changer for this query.