title: SQL: Filter data by datetime
body: <p>I have a massive table I'm trying to thin out in MS SQL Server Management Studio. Currently there is a row for every 5 seconds of data. I want to shrink the table and only save 1 row for every 30 minutes. </p>
  
  <p>For example, instead of having thousands of rows at</p>
  
  <pre><code>    Timestamp            A   B   C
      2015-01-01 00:00:00  1   5   6
      2015-01-01 00:00:05  5   7   1
      2015-01-01 00:00:10  2   2   3
      2015-01-01 00:00:15  2   1   0
      ......
      2015-04-10 13:55:55  4   5   6
      2015-04-10 13:56:00  6   4   2
  </code></pre>
  
  <p>I want to thin it out so I only have</p>
  
  <pre><code>    Timestamp            A   B   C
      2015-01-01 00:00:00  1   5   6
      2015-01-01 00:30:00  2   5   7
      2015-01-01 01:00:00  1   7   6
      ......
      2015-04-10 13:30:00  4   5   6
      2015-04-10 14:00:00  6   4   2
  </code></pre>
  
  <p>Thank you!</p>