take a look at the ROLLUP and CUBE keywords in the "Oracle8i Datawarehousing Guide " section 17 SQL for Analysis.
I think the syntax is something like this :
select blabla1,blabla2, sum(amount)
from blablatable
group by rollup(blabla1,blabla2)
Regards
Gert




Reply With Quote