Run-Based Semantics for RPQs

11/23/2022
by   Claire David, et al.
0

The formalism of RPQs (regular path queries) is an important building block of most query languages for graph databases. RPQs are generally evaluated under homomorphism semantics; in particular only the endpoints of the matched walks are returned. Practical applications often need the full matched walks to compute aggregate values. In those cases, homomorphism semantics are not suitable since the number of matched walks can be infinite. Hence, graph-database engines adapt the semantics of RPQs, often neglecting theoretical red flags. For instance, the popular query language Cypher uses trail semantics, which ensures the result to be finite at the cost of making computational problems intractable. We propose a new kind of semantics for RPQs, including in particular simple-run and binding-trail semantics, as a candidate to reconcile theoretical considerations with practical aspirations. Both ensure the output to be finite in a way that is compatible with homomorphism semantics: projection on endpoints coincides with homomorphism semantics. Hence, testing the emptiness of result is tractable, and known methods readily apply. Moreover, simple-run and binding-trail semantics support bag semantics, and enumeration of the bag of results is tractable

READ FULL TEXT
research
03/17/2018

Datalog: Bag Semantics via Set Semantics

Duplicates in data management are common and problematic. In this work, ...
research
04/13/2023

Conjunctive Regular Path Queries under Injective Semantics

We introduce injective semantics for Conjunctive Regular Path Queries (C...
research
12/23/2021

Determinacy of Real Conjunctive Queries. The Boolean Case

In their classical 1993 paper [CV93] Chaudhuri and Vardi notice that som...
research
06/24/2019

Bag Query Containment and Information Theory

The query containment problem is a fundamental algorithmic problem in da...
research
07/02/2021

Temporal Regular Path Queries

In the last decade, substantial progress has been made towards standardi...
research
10/30/2020

Independence in Infinite Probabilistic Databases

Probabilistic databases (PDBs) model uncertainty in data. The current st...
research
02/22/2022

Revisiting Semiring Provenance for Datalog

Data provenance consists in bookkeeping meta information during query ev...

Please sign up or login with your details

Forgot password? Click here to reset