arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2208.03586cs.DBcs.DS
收藏

在具有后期物化的列存储中实现窗口函数(扩展版)

Implementing Window Functions in a Column-Store with Late Materialization (Extended Version)

Nadezhda Mukhaleva, Valentin Grigorev, George Chernishev

摘要:

窗口函数是聚合操作的一般化。与聚合不同,其输出的基数总是与输入的基数相同。也就是说,该运算符的语义意味着计算每行的额外属性的值,这取决于它的上下文,由滑动窗口或先前评估的行表示。窗口函数是一个非常强大的工具,它在数据分析师中也很流行,并得到大多数工业DBMS的支持。它允许优雅地表达相当复杂的用例,例如运行总和和平均值,局部最大值和最小值以及不同类型的排名。由于它们可以在没有自连接和相关子查询的情况下表达,因此可以更有效地执行它们的评估。在本文中,我们讨论了一个基于磁盘的列存储与后期物化的窗口函数的实现。后期物化是一种技术,旨在尽可能长时间地保留单个列的元组重构。最初流行于00年代后期,现在很少被考虑。然而,在窗口函数的情况下,它允许大大降低内存占用。本文的另一个贡献是段树计算范围为基础的窗口函数的应用。

英文摘要:

A window function is a generalization of the aggregation operation. Unlike aggregation, the cardinality of its output is always the same as the cardinality of input. That is, the semantics of this operator imply computing values for extra attributes for each row, depending on its context, either expressed by a sliding window or a previously evaluated row. Window functions are a very powerful tool, which is also popular among data analysts and supported by the majority of industrial DBMSes. It allows to gracefully express quite complex use-cases, such as running sums and averages, local maximum and minimum, and different types of ranking. Since they can be expressed without self-joins and correlated subqueries, their evaluation can be performed much more efficiently. In this paper we discuss an implementation of window functions inside a disk-based column-store with late materialization. Late materialization is a technique that aims to keep tuple reconstruction back from individual columns as long as possible. Initially popular in the late 00's, it is rarely considered nowadays. However, in case of window functions it allows to substantially lower memory footprint. Another contribution of this paper is the application of a segment tree to computing RANGE-based window functions.

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

↑