title: Oracle TRUNC date by quarter but with custom year start date
body: <p>I need to get aggregate values on a quarterly basis which can be done using the trunc function with the option 'Q' like so</p>
  
  <pre><code>select count(*), trunc(DATE_COL, 'Q') from TABLE_NAME
  group by trunc(DATE_COL, 'Q')
  </code></pre>
  
  <p>But the problem here is that I need the year to start on the 1st Dec of the previous year instead of 1st Jan (Ex: the Q1 2015 starts on 1-Dec-2014 and ends on 28-Feb-2015, as opposed to 1-Jan-2015 to 31-Mar-2015).
  Added: So Q1 includes Dec, Jan, Feb; Q2 includes Mar, Apr, May; Q3 includes Jun, Jul, Aug; Q4 includes Sep, Oct, Nov</p>
  
  <p>PS: I'm using Oracle 11g and I'll be running these queries via PHP 5.3.  </p>