arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2407.06766cs.DB
收藏

GQL查询的求值复杂度

Complexity of Evaluating GQL Queries

CNRS, LaBRI, Univ. Bordeaux(法国国家科学研究中心,拉布里实验室,波尔多大学);University of Kaiserslautern-Landau and MPI-SWS(凯泽斯劳滕-兰道大学与马克斯·普朗克计算机科学研究所);Hebrew University of Jerusalem(耶路撒冷希伯来大学)

Diego Figueira, Anthony W. Lin, Liat Peterfreund

AI总结:

本文解决了GQL查询求值复杂度的基础问题,证明其一般数据复杂度为P^NP[log]完全、无限制器时为NL完全,且该结论对无限具体域查询也成立,同时建立了GQL与关系查询语言及二阶逻辑片段的紧密关联。

摘要:

GQL(图查询语言)近来已成为图数据库(尤其是属性图模型)的标准查询语言,其地位类似于SQL在关系数据库中的角色。但与SQL不同的是,GQL的基础问题迄今仍未解决,最突出的是查询求值复杂度问题。本文针对该问题给出了完整解答:我们证明GQL的数据复杂度在一般情况下是P^NP[log]完全的,若不允许使用所谓的“限制器(restrictors)”则为NL完全的。借助嵌入有限模型理论的技术,我们证明即便查询使用来自无限具体域(例如允许在查询中进行算术运算的实数域)的数据,上述结论依然成立。在证明这些结果的过程中,我们建立并利用了GQL与关系数据库查询语言之间的紧密关联,特别是带传递闭包算子的关系演算扩展,以及二阶逻辑的一个片段。

英文摘要:

GQL has recently emerged as the standard query language over graph databases (particularly, the property graph model). Indeed, this is analogous to the role of SQL for relational databases. Unlike SQL, however, fundamental problems regarding GQL are hitherto still unsolved, most notably the complexity of query evaluation. In this paper we provide a complete solution to this problem. In particular, we show that the data complexity of GQL is $\text{P}^{\text{NP}[\log]}$-complete in general, and is $\text{NL}$-complete, when the so-called ``restrictors'' are disallowed. Using techniques from embedded finite model theory, we show that this is true, even when the queries use data from infinite concrete domains (for example the domain of real numbers where arithmetic is allowed in the query). In proving these results, we establish and exploit tight connections between GQL and query languages over relational databases, especially the extension of relational calculus with transitive closure operators, and a fragment of second-order logic.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑