Skip to Main Content

SQL & PL/SQL

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Sum, cumulate

crupperFeb 6 2007 — edited Feb 6 2007
hi,

select nr,
quarter,
sum(amount) amount
from mad_test
group by nr,
quarter


nr quarter amount total_sum_nr
-- ------- ------ ------------
01 Q012004 5
01 Q022004 2
01 Q032004 10 17
02 Q012004 8
02 Q012006 8 16
05 Q022006 10
05 Q032006 10
05 Q042006 10 30

I would like to have the amounts 17,16,30 of column >>total_sum_nr<<

Does anybody have an idea?
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Mar 6 2007
Added on Feb 6 2007
2 comments
248 views