title: How to generate row of time sequences using SQL (SQL-Server)
body: <p>Right now, I want to create function that generate row of time sequence from date x to date y using SQL.</p>
  
  <p>The function have two date inputs: x and y. They are date without time (i.e. time is 00:00:00). The function will look like this:</p>
  
  <p><code>function (@x date, @y date)</code></p>
  
  <p>Then, the result will generate rows of time sequence from date x to date y. Each time has difference of 15 minutes. The result will not include date y.</p>
  
  <p>For example, if I call function ('2013-06-19', '2013-06-21'), the result will be:</p>
  
  <p>'2013-06-19 00:00:00' <br>
  '2013-06-19 00:15:00' <br>
  '2013-06-19 00:30:00' <br>
  ... <br>
  '2013-06-19 23:30:00' <br>
  '2013-06-19 23:45:00' <br>
  '2013-06-20 00:00:00' <br>
  '2013-06-20 00:15:00' <br>
  ... <br>
  '2013-06-20 23:30:00' <br>
  '2013-06-20 23:45:00' <br></p>