Adopting Worst-Case Optimal Joins in Relational Database Systems
Michael J. Freitag, Maximilian Bandle, Tobias Schmidt, Alfons Kemper, Thomas Neumann
Abstract
Worst-case optimal join algorithms are attractive from a theoretical point of view, as they offer asymptotically better runtime than binary joins on certain types of queries. In particular, they avoid enumerating large intermediate results by processing multiple input relations in a single multi-way join. However, existing implementations incur a sizable overhead in practice, primarily since they rely on suitable ordered index structures on their input. Systems that support worst-case optimal joins often focus on a specific problem domain, such as read-only graph analytic queries, where extensive precomputation allows them to mask these costs. In this paper, we present a comprehensive implementation approach for worst-case optimal joins that is practical within general-purpose relational database management systems supporting both hybrid transactional and analytical workloads. The key component of our approach is a novel hash-based worst-case optimal join algorithm that relies only on data structures that can be built efficiently during query execution. Furthermore, we implement a hybrid query optimizer that intelligently and transparently combines both binary and multi-way joins within the same query plan. We demonstrate that our approach far outperforms existing systems when worst-case optimal joins are beneficial while sacrificing no performance when they are not.
Ask about this paper
Your agent reads all of it.
Lune indexed this paper to the last equation, along with the top-tier papers that cite it. Ask a question and the answer quotes them.
Your agent calls
Luneget_paper_fulltext
Free to start. No credit card required.
Terminal
Install the CLIlune papers fulltext f487948d-0b56-483f-93f2-5ebd60dd6077Cited by top-tier papers31
- The LDBC Social Network Benchmark: Business Intelligence WorkloadGábor Szárnyas, Jack Waudby, Benjamin A. Steer, Dávid Szakállas et al.VLDB 2023 · 103 citations
- Worst-Case Optimal Graph Joins in Almost No SpaceDiego Arroyuelo, Aidan Hogan, Gonzalo Navarro, Juan L. Reutter et al.SIGMOD 2021 · 34 citations
- Making RDBMSs Efficient on Graph Workloads Through Predefined JoinsGuodong Jin, Semih SalihogluVLDB 2022 · 24 citations
- Robust Join Processing with Diamond Hardened JoinsAltan Birler, Alfons Kemper, Thomas NeumannVLDB 2024 · 23 citations
- Optimizing Tensor Programs on Flexible StorageMaximilian Schleich, Amir Shaikhha, Dan SuciuSIGMOD 2023 · 21 citations
Related papers
- Free Join: Unifying Worst-Case Optimal and Traditional JoinsYisu Remy Wang, Max Willsey, Dan SuciuSIGMOD 2023 · 18 citations
- HoneyComb: A Parallel Worst-Case Optimal Join on MulticoresJiacheng Wu, Dan SuciuSIGMOD 2025 · 1 citation
- Rethink Query Optimization in HTAP DatabasesHaoze Song, Wenchao Zhou, Feifei Li, Xiang Peng et al.SIGMOD 2024 · 7 citations
- ADOPT: Adaptively Optimizing Attribute Orders for Worst-Case Optimal Join Algorithms via Reinforcement LearningJunxiong Wang, Immanuel Trummer, Ahmet Kara, Dan OlteanuVLDB 2023 · 10 citations
- How to Optimize SQL Queries? A Comparison Between Split, Holistic, and Hybrid ApproachesLuca Gretscher, Jens DittrichVLDB 2025
