Windowing Function With Aggregate Function
February 23, 2015
|
SELECT
num,
MAX(num) OVER (ROWS BETWEEN CURRENT ROW AND 1 FOLLOWING) as max_here_1_following
FROM
( SELECT 2 AS num),
( SELECT 4 AS num),
( SELECT 3 AS num),
( SELECT 1 AS num),