Worst-case optimal join algorithm



A worst-case optimal join algorithm is an algorithm for computing relational joins with a runtime that is bounded by the worst-case output size of the join. Traditional binary join algorithms such as hash join operate over two relations at a time; joins between more than two relations are implemented by repeatedly applying binary joins. Worst-case optimal join algorithms are asymptotically faster in worst case than any join algorithm based on such iterated binary joins.

The first worst-case optimal join algorithm, generic join, was published in 2012. Worst-case optimal join algorithms have been implemented in commercial database systems, including the LogicBlox system. Worst-case optimal joins have been applied to build a worst-case optimal algorithm for e-matching.