5 ms·
My mental model was always that the order of keywords mirrored the order the database engine applied them. So WHERE is processed first and SELECT last.
by jimlikeslimes 3y ago
My mental model was always that the order of keywords mirrored the order the database engine applied them. So WHERE is processed first and SELECT last.
- deleted 3y ago[deleted]
- baq 3y agotry EXPLAIN ANALYZE (or just plain EXPLAIN) and see for yourself!
- defaultcompany 3y agoIt’s not really mirrored (assuming you meant reversed). Here’s a page describing the two orders in relation to each other from a wiki I wrote: https://github.com/weinberg/SQLToy/wiki/Two-Key-Concepts https://github.com/weinberg/SQLToy/wiki/Two-Key-Concepts
- jimlikeslimes 3y agoOh wow, the wiki / project looks fantastically interesting. I've bookmarked it for a deeper read in the future. Yes I did mean reversed.