Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.misc -> Recursive Reference in SQL Calc

Recursive Reference in SQL Calc

From: Ian Jones <ianj_at_gene.com>
Date: 14 Mar 2002 16:52:46 -0800
Message-ID: <5b9fed14.0203141652.ec41262@posting.google.com>


given the following table structure

id,...,date_initiated, date_closed,...

how would one do the following calculation for a date range, grouped by month/year for charting purposes:

count pending this month =

       count pending last month + 
            count initiated this month -
                 count closed this month

assuming the first month's count pending is:

count initiated first month - count closed first month

Thanks!!
Ian Received on Thu Mar 14 2002 - 18:52:46 CST

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US