title: Oracle window function with dates
body: <p>Sample data is as follows:  </p>
  
  <pre><code>date       value  
  2015-09-09      1  
  2015-09-08      2  
  2015-09-07      3  
  2015-09-04      4  
  2015-09-03      5  
  </code></pre>
  
  <p>I need to calculate sum value for each date and two days before, so the result should appear:</p>
  
  <pre><code>2015-09-09      6 --sum value of 2015-09-09, 2015-09-08, 2015-09-07  
  2015-09-08      5 --sum value of 2015-09-08, 2015-09-07  
  2015-09-07      3 --sum value of 2015-09-07  
  2015-09-04      9 --sum value of 2015-09-04, 2015-09-03  
  2015-09-03      5 --sum value of 2015-09-03  
  </code></pre>
  
  <p>How could I achieve it with window functions in Oracle?</p>