Order-Dependent Complexity of Enumeration and Direct Access for Conjunctive Queries on Dynamic Data
Antoine Amarilli, Nofar Carmeli, Cl\'emence Dumoulin
Key points
From the paper's conclusion- This note studies the fine-grained complexity of ranked enumeration and ranked direct access of conjunctive query answers over a dynamic database.
Abstract
This note studies the fine-grained complexity of ranked enumeration and ranked direct access of conjunctive query answers over a dynamic database. We focus on lexicographically sorted answers, defined by an ordering on the query's free variables. From the literature, when no particular order is required, we know that when the query is self-join-free and q-hierarchical, we can build a data structure for enumeration (resp. direct access) with linear (resp. linearithmic) preprocessing and constant (resp. logarithmic) update time in the size of the database. For enumeration (resp. direct access), this data structure yields an algorithm that enumerates all query answers (resp. that returns the $k$-th query answer) with constant delay (resp. logarithmic access time). Our goal is to extend these results to ranked enumeration and ranked direct access, with the ranking function defined by a lexicographic order. We define a property on the order over the variables of $Q$, which we call being hierarchy-consistent. Given a user-specified query and hierarchy-consistent order, we first propose, for ranked enumeration under updates, an algorithm with linear preprocessing and logarithmic update time that enumerates all the query answers according to the user-specified order with constant delay. Moreover, for ranked direct access under updates, we propose an algorithm with linear preprocessing and logarithmic update time that returns the $k$-th tuple according to the user-specified order with logarithmic access time. In contrast, given a user-specified query and non-hierarchy-consistent order, we show a lower bound for ranked direct access under updates.
Read the paper
Discussion
Science Skim's AI key points, plus readers' public thoughts
Readers' thoughts
No reader thoughts yet.
Related papers
- Yannakakis + : Practical Acyclic Query Evaluation with Theoretical GuaranteesACM Transactions on Database Systems · 2026
- Few Rows Tell Them Apart: Equivalence of Queries Mixing Set and Bag SemanticsarXiv · 2026
- Extremal Fitting Problems for Conjunctive QueriesJournal of the ACM · 2026
- Attacking Diophantus: Special Cases of Bag ContainmentarXiv · 2026
- Testability of Homomorphism Inadmissibility: Property Testing Meets Database TheoryarXiv · 2026
- Online and Fully-Dynamic SortingarXiv · 2026