你说“什么”,我听到“在哪里”和“为什么”:(错误)解释SQL以获得细粒度出处
You Say 'What', I Hear 'Where' and 'Why': (Mis-)Interpreting SQL to Derive Fine-Grained Provenance
摘要:
SQL声明性地指定查询的期望输出是什么。这项工作表明,SQL语义的非标准解释可以揭示输出的一部分来自输入的哪里,以及为什么这部分会进入结果。我们在各个表单元格的细粒度级别上为非常丰富的SQL方言(包括递归、窗口聚合和用户定义函数)推导出这样的数据出处。该方法是非侵入性的,并实现为组合源代码级SQL重写:输入SQL查询被转换为自己的解释器,该解释器使用数据依赖关系而不是常规值。我们故意设计这种转换,以保持数据和查询的形状,这使得起源派生扩展到复杂的查询,而不会压倒底层的数据库系统。
英文摘要:
SQL declaratively specifies what the desired output of a query is. This work shows that a non-standard interpretation of the SQL semantics can, instead, disclose where a piece of the output originated in the input and why that piece found its way into the result. We derive such data provenance for very rich SQL dialects (including recursion, windowed aggregates, and user-defined functions) at the fine-grained level of individual table cells. The approach is non-invasive and implemented as a compositional source-level SQL rewrite: an input SQL query is transformed into its own interpreter that wields data dependencies instead of regular values. We deliberately design this transformation to preserve the shape of both data and query, which allows provenance derivation to scale to complex queries without overwhelming the underlying database system.
机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。