Viewing post 1 (of 1 total)
Rolling average of current row and previous 4. Only good for SQL 2012
WITH Numbers AS
(SELECT 1 AS Nr
UNION ALL
SELECT Nr + 1
FROM Numbers
WHERE Nr < 100
)
SELECT
Nr,
CASE
WHEN Nr >= 5
THEN...
December 9, 2013 at 12:03 pm
#1672091