Sliding Window (or Rolling Window)

<< Click to Display Table of Contents >>

Navigation:  Glossary >

Sliding Window (or Rolling Window)

Previous pageReturn to chapter overviewNext page

A sliding or rolling window emits an output row with every input row and flushes a small number (often times 1) of rows out of the window for the next calculation. Aside from the small number flushed, sliding windows continue to accumulate rows. Sliding windows are used for windowed aggregation. In contrast, a tumbling window is a collection of rows that are aggregated to produce a fewer number of output rows.  The window is "tumbling" because after the output rows are emitted, the tumbling window is cleared and a new set of future rows are accumulated for the next output. As a result, the total number of output rows are limited.