| Oracle FAQ | Your Portal to the Oracle Knowledge Grid | |
Home -> Community -> Usenet -> comp.databases.oracle -> Re: Query Help
> mackdaddy315_at_hotmail.com (DM) wrote in message news:<bf2880e.0405180921.20de01f_at_posting.google.com>...
I appologize, unfortunately right after I sent in that post I realized I didn't include some of the more complicating factors and made my example too easy. But I came up with a solution to this and figured I would post it since I started the discussion even if it was the wrong one :).
SQL> Select a.Year, a.Col1,Sum(b.Col1)
2 From foo a, foo b
3 Where a.year >= b.year
4 Group by a.Year, a.Col1
5 Order by 1, 2;
YEAR COL1 SUM(B.COL1)
--------- --------- -----------
2003 10 10
2004 10 20
2005 10 30
2006 10 40
2007 10 50
2008 10 60
6 rows selected. Received on Wed May 19 2004 - 10:19:04 CDT
![]() |
![]() |