May 16, 2019 at 7:18 am
Can RANGE window function take user input as value for interval and ranges instead of unbounded preceding and current row?
May 16, 2019 at 3:19 pm
It's simple enough to test. Have you done so?
Drew
J. Drew Allen
Business Intelligence Analyst
Philadelphia, PA
May 16, 2019 at 9:28 pm
OVER clause: https://docs.microsoft.com/en-us/sql/t-sql/queries/select-over-clause-transact-sql?view=sql-server-2017
If you mean something like this, you can't do this:
declare @i int = 2;
select sum(a) over (partition by b
order by c
rows between current row and @i following
)
from mytable
Viewing 4 posts - 1 through 4 (of 4 total)
You must be logged in to reply to this topic. Login to reply