title: Oracle SQL to get count of first occurrences of a row in the full data set filtered by date?
body: <p>We have a dataset that looks like this:</p>
  
  <pre><code>ID       eventType     date
  --------------------------------
  1        foo           2 March 2013
  2        foo           3 March 2013
  3        bar           3 March 2013
  4        foo           5 March 2013
  5        foo           6 March 2013
  6        bar           7 March 2013
  7        baz           8 March 2013
  </code></pre>
  
  <p>I can easily get the unique list of <code>eventTypes</code> from this list.  However, how do I query the count of which <code>eventTypes</code> first appeared BETWEEN <code>startDate</code> and <code>endDate</code>.  I want to be able to have a date range from 7 March 2013 - 10 March 2013 and get a count returned of 1 since <code>baz</code> value was a newly occurring <code>eventType</code> during the date range.  On the other hand, a date range of 5 March 2013 - 7 March 2013 would return a count of 0 since no newly occurring <code>eventTypes</code> appeared in that range.</p>