Skip to main content

Join Algorithms

Learn Join Algorithms (Query Optimization, MySQL) with worked examples, diagrams and interview questions. Free on JavaSchoolLab.

Introduction MySQL joins tables with Nested Loop Join (for each outer row, look up matches in the inner table, ideally via an index), Block Nested Loop (legacy, buffered), and Hash Join (8.0.18+, builds an in-memory hash table on the smaller input then probes it).

More lessons in Query Optimization