Joins (Joins)

From Algorithm Wiki
Revision as of 14:35, 15 February 2023 by Admin (talk | contribs)
Jump to navigation Jump to search

Description

An SQL join clause - corresponding to a join operation in relational algebra - combines columns from one or more tables in a relational database.

Parameters

n, m: sizes of input tables

Table of Algorithms

Name Year Time Space Approximation Factor Model Reference
Nested loop join 1960 $O(nm)$ $O({1})$ Exact Deterministic
Sort merge join 1960 $O(nlogn + mlogm)$ $O(n+m)$? Exact Deterministic
Hash join 1960 $O(n+m)$ $O(n+m)$? Exact Deterministic

Time Complexity Graph

Joins - Time.png

Space Complexity Graph

Joins - Space.png

Space-Time Tradeoff Improvements

Joins - Pareto Frontier.png