title: How GROUP BY and OVER WINDOW differ in FlinkSQL?
body: <p>One can use windows in Flink in two different manners</p>
  
  <pre><code>SELECT key, MAX(value)
    FROM table
   GROUP BY key, TUMBLE(ts, INTERVAL '5' MINUTE)
  </code></pre>
  
  <p>and</p>
  
  <pre><code>SELECT key, MAX(value) OVER w
    FROM table
   WINDOW w AS (PARTITION BY key ORDER BY ts ROWS BETWEEN UNBOUNDED PRECEDING AND CURRENT ROW)
  </code></pre>
  
  <p>I wonder if those two mechanisms can express the same thing or what's the main difference and possible use cases for both?</p>