title: Grouping data by time interval
body: <p>I want to group the data in a table by time interval. The table keeps the order info that includes the userid, item name, model, quantity, activity date, etc. Now I want to group this data by time intervals. The time interval could be anything like 5 min, 10 min, 15, etc. Also, the query should return only those users (all the column data) who made orders more than once within that 5 minutes interval. Is it possible to achieve this in one SQL query? I use Oracle.</p>
  
  <p>Thank you</p>
  
  <p><strong>Edit:</strong></p>
  
  <p>Sample data</p>
  
  <pre><code>**userid    item name    model      quantity   order date**
  abc calculator   cdm83ss    1      02-FEB-2013 09:20:13     
  abc alarm clock  actp001    1      02-FEB-2013 09:26:22
  yyy iPhone       iP4    1      02-FEB-2013 09:28:14
  abc alarm clock  actz321    2      02-FEB-2013 09:30:00
  zzz backpack     bp344tk    1      04-FEB-2013 13:15:00
  zzz backpack     bp234zz    2      04-FEB-2013 13:19:32
  zzz camera       cm234  1      04-FEB-2013 13:20:22 
  ttt tv       fs45yup    1      04-FEB-2013 13:28:19
  </code></pre>
  
  <p>I expect to get:</p>
  
  <pre><code>**userid    item name    model      quantity   order date**
  abc         calculator   cdm83ss    1      02-FEB-2013 09:20:13     
  abc         alarm clock  actp001    1      02-FEB-2013 09:26:22
  abc         alarm clock  actz321    2      02-FEB-2013 09:30:00
  zzz         backpack     bp344tk    1      04-FEB-2013 13:15:00
  zzz         backpack     bp234zz    2      04-FEB-2013 13:19:32
  zzz         camera       cm234  1      04-FEB-2013 13:20:22 
  </code></pre>