title: ORACLE SQL: Select records with time difference less than a minute
body: <p>I have a table in which I have same the records but with different timestamps.
  E.g. - 1</p>
  
  <pre><code>2015-03-03 13:41:11.0  [createService]: [accountNumber = 123456]
  2015-03-02 01:19:11.0  [createService]: [accountNumber = 123456]
  2015-03-02 01:19:06.0  [createService]: [accountNumber = 123456]
  </code></pre>
  
  <p>E.g. - 2</p>
  
  <pre><code>2015-03-07 01:21:11.0  [createService]: [accountNumber = 567890]
  2015-03-04 01:17:11.0  [createService]: [accountNumber = 567890]
  </code></pre>
  
  <p>I need to pull only the records that have more than 2 rows with a time difference of less than a minute on any single day. In the examples above i should only pull account 123456 since it has 2 records on the same day with a time difference of less than 60 seconds.</p>
  
  <p>This is the query ive used to pull all records that have the createservice row more than once but need to filter the list furhter with the condition above -</p>
  
  <pre><code>SELECT acct_number
  FROM CUSTOMER_LOG
  WHERE LOG_EVENT LIKE '%createService%serviceName%'
  AND LOG_EVENT_TMST &gt; to_date('03/01/2015 00:00:00','MM/DD/YYYY HH24:MI:SS')
  GROUP BY ACCT_NUMBER
  having count(ACCT_NUMBER) &gt; 1;
  </code></pre>
  
  <p>Could you please help me with a query that can accomplish this in the fastest time? Thank you in advance!</p>