Nav-Index: A High-Performance, Adaptive Index for Shortest Path Queries in RDBMS
Maximilian Reif, Thomas Neumann
Abstract
Shortest path queries are a fundamental operation on graphs with numerous applications. Efficiently executing shortest path searches in RDBMS is challenging, as graphs can not only be static relations but might also occur as ad-hoc intermediate results of complex analytical queries. Especially single-pair shortest path queries are difficult to accelerate, because they require minimizing the search space and intermediate results cannot be shared e.g. for multiple destinations. To address these challenges, we present Nav-Index, an adaptive index for relational DBMS that accelerates large-scale shortest path queries with seamless integration into SQL and relational algebra. Nav-Index switches adaptively between three modes: an ad-hoc generic mode using Dijkstra's algorithm, an ad-hoc optimized mode for sparse graphs leveraging contraction hierarchies (CH), and a table index mode for static graphs also leveraging CHs.
Graph DBMS typically provide specific implementations for such queries and are valuable for many workloads. In practice, however, existing systems show limited throughput for large-scale graphs such as road networks and offer limited optimization for analytical relational processing. Embedding Nav-Index into an RDBMS allows for a seamless composition with other relational operators, query decorrelation, cost-based optimization, morsel-driven parallelism, and pipelining. In the case of sparse graphs, Nav-Index's CH mode transforms the graph into a contraction hierarchy, allowing algorithmic speedups by orders of magnitude.
We implemented Nav-Index into the compiling RDBMS Umbra and evaluate it extensively on road networks from small cities to the whole planet and social graphs. In our experiments, Nav-Index outperforms all other database systems that we have tested by orders of magnitude due to algorithmic advantages and an efficient implementation. It can index the road network of Europe in under 12 minutes and Earth in less than 68 minutes, allowing planet-scale shortest path queries in milliseconds in a general-purpose RDBMS.
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.
Builds on4
- 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
- Robust Join Processing with Diamond Hardened JoinsAltan Birler, Alfons Kemper, Thomas NeumannVLDB 2024 · 23 citations
- Breaking the Sorting Barrier for Directed Single-Source Shortest PathsRan Duan, Jiayi Mao, Xiao Mao, Xinkai Shu et al.STOC 2025 · 8 citations
- Robust Recursive Query Parallelism in Graph Database Management SystemsAnurag Chakraborty, Semih SalihogluVLDB 2025
Related papers
- Towards Efficient Shortest Path Counting on Billion-Scale GraphsYiqi Wang, Long Yuan, Zi Chen, Wenjie Zhang et al.ICDE 2023 · 21 citations
- Efficient Shortest Path Index Maintenance on Dynamic Road Networks with Theoretical GuaranteesDian Ouyang, Long Yuan, Lu Qin, Lijun Chang et al.VLDB 2020 · 79 citations
- Efficient Shortest Path Counting on Large Road NetworksYu-Xuan Qiu, Dong Wen, Lu Qin, Wentao Li et al.VLDB 2022 · 22 citations
- NaviX: A Native Vector Index Design for Graph DBMSs With Robust Predicate-Agnostic Search PerformanceGaurav Sehgal, Semih SalihogluVLDB 2025 · 12 citations
- A Robust and Globally-Accurate Hierarchical Hub Labeling Index for SP-Distance Queries in Dynamic Road NetworksWei Liu, Ziqiang Yu, Xiaohui Yu, Yang Liu et al.ICDE 2026
