Skip to main content
QUICK REVIEW

[Paper Review] Answering UCQs under Updates and in the Presence of Integrity Constraints

Christoph Berkholz, Jens Keppeler|arXiv (Cornell University)|Sep 28, 2017
Logic, Reasoning, and KnowledgeComputer Science18 references6 citations
TL;DR

This paper introduces a hierarchy of unions of conjunctive queries (UCQs)—t-hierarchical, q-hierarchical, and exhaustively q-hierarchical—that precisely characterizes the tractability of dynamic query evaluation under updates. It proves that for these classes, testing, enumeration, and counting can be maintained with constant update and response times, while outside these classes, sublinear performance is impossible under standard algorithmic conjectures.

ABSTRACT

We investigate the query evaluation problem for fixed queries over fully dynamic databases where tuples can be inserted or deleted. The task is to design a dynamic data structure that can immediately report the new result of a fixed query after every database update. We consider unions of conjunctive queries (UCQs) and focus on the query evaluation tasks testing (decide whether an input tuple belongs to the query result), enumeration (enumerate, without repetition, all tuples in the query result), and counting (output the number of tuples in the query result). We identify three increasingly restrictive classes of UCQs which we call t-hierarchical, q-hierarchical, and exhaustively q-hierarchical UCQs. Our main results provide the following dichotomies: If the query's homomorphic core is t-hierarchical (q-hierarchical, exhaustively q-hierarchical), then the testing (enumeration, counting) problem can be solved with constant update time and constant testing time (delay, counting time). Otherwise, it cannot be solved with sublinear update time and sublinear testing time (delay, counting time), unless the OV-conjecture and/or the OMv-conjecture fails. We also study the complexity of query evaluation in the dynamic setting in the presence of integrity constraints, and we obtain according dichotomy results for the special case of small domain constraints (i.e., constraints which state that all values in a particular column of a relation belong to a fixed domain of constant size).

Motivation & Objective

  • To identify the precise tractability frontier for dynamic query evaluation of unions of conjunctive queries (UCQs) under database updates.
  • To extend prior work on conjunctive queries (CQs) to UCQs by introducing three increasingly restrictive classes: t-hierarchical, q-hierarchical, and exhaustively q-hierarchical.
  • To analyze the impact of integrity constraints—especially small domain constraints—on the dynamic complexity of UCQ evaluation.
  • To establish tight lower bounds based on the OMv-conjecture and OV-conjecture, showing that sublinear update and response times are impossible outside the defined classes.
  • To demonstrate that inclusion and functional dependencies can transform hard queries into tractable ones, but that such transformations are not always captured by hierarchical query classes.

Proposed method

  • Introduce the concept of t-hierarchical CQs as a new class that characterizes constant-time testing in dynamic query evaluation.
  • Extend the notions of t-hierarchical and q-hierarchical queries to UCQs and define the new class of exhaustively q-hierarchical UCQs.
  • Design dynamic data structures that support linear preprocessing, constant update time, and constant response time (testing, enumeration delay, counting time) for queries in the defined classes.
  • Prove matching lower bounds using the OMv-conjecture and OV-conjecture, showing that sublinear update and response times are impossible for non-hierarchical queries.
  • Analyze the effect of small domain constraints (fixed-size domains per attribute) and show that they can make otherwise hard queries tractable, with a precise characterization of tractable UCQs in this setting.
  • Use structural query decomposition and homomorphic core analysis to relate query structure to dynamic complexity, especially via atom dependency and variable usage patterns.

Experimental results

Research questions

  • RQ1What classes of UCQs allow for constant-time update and response in dynamic query evaluation?
  • RQ2How do t-hierarchical, q-hierarchical, and exhaustively q-hierarchical UCQs relate to each other, and what structural properties define them?
  • RQ3Can integrity constraints such as small domain constraints or inclusion dependencies transform hard queries into tractable ones in the dynamic setting?
  • RQ4What are the tight lower bounds for dynamic query evaluation under standard algorithmic conjectures?
  • RQ5To what extent can functional dependencies or inclusion dependencies be used to reduce a hard query to a tractable one, and can such reductions be captured by hierarchical query classes?

Key findings

  • For every t-hierarchical UCQ, the testing problem can be solved with linear preprocessing, constant update time, and constant testing time.
  • For every q-hierarchical UCQ, the enumeration problem can be solved with linear preprocessing, constant update time, and constant delay between output tuples.
  • For every exhaustively q-hierarchical UCQ, the counting problem can be solved with linear preprocessing, constant update time, and constant counting time.
  • If a UCQ is not equivalent to a t-hierarchical (q-hierarchical, exhaustively q-hierarchical) UCQ, then the testing (enumeration, counting) problem cannot be solved with sublinear update time and sublinear response time, assuming the OMv-conjecture (and OV-conjecture for counting).
  • In the presence of small domain constraints, the tractability frontier for dynamic UCQ evaluation is precisely characterized by the t-hierarchical, q-hierarchical, and exhaustively q-hierarchical classes.
  • Inclusion dependencies can transform non-hierarchical queries into equivalent hierarchical ones, but such transformations are not always possible via iterative application, and not all such reductions are captured by the hierarchical classes.

Read this paper

Open the full text in the Nubint reader and ask about any passage as you read.

Read this paper on Nubint

This review was generated by AI from the original paper. Please check the paper before citing it.