Hi,
How do I write an SQL that will give results based on a moving window based on a date range?
For e.g. in the following table
for a given I want to produce the sum of AmtCol between the last month and the next following month.
How do I write an SQL that will give results based on a moving window based on a date range?
For e.g. in the following table
Code:
KeyCol AmtCol DateCol
1 10 2013-01-01
2 20 2013-02-01
3 30 2013-03-01
4 40 2013-04-01