3 ms·
I think this guide misses the point that “JOIN” is not a root keyword but a modification on “FROM”. It is more akin to logical “AND”, “OR”, etc. And this stack
by seer 2y ago
I think this guide misses the point that “JOIN” is not a root keyword but a modification on “FROM”. It is more akin to logical “AND”, “OR”, etc.
And this stacks much better once you start doing complex joins especially when you can add parentheses to change where you actually join
FROM a JOIN b JOIN c
Can be different than
FROM a JOIN (b JOIN C)
Apart from that I think I came up independently to the exact same rules when building the prettier extension for SQL a few years back.
- steve_gh 2y agoSQLis based on set theory, which is asdociative. So (a JOIN b) JOIN c = a JOIN (b JOIN c) Your DB's query planner should optimise given the available indices.