I want to get a summation for some fields in a result-set
over more than one group level. I have no Olap-Functions on the DB-Server ( iSeries V5R3 ),
so I have to do it with Java.
Is there a possibility to do it with ibatis-SQL-Map?
e.g.:
select sum(pieces), company, customer from mytable group by
company, customer
order by company, customer
I want to get a list with Objects from Ibatis with the following data:
pieces CompanyId customerId isSum
1 A 1 no
1 A 1 no
1 A 1 no
3 A 1 yes
1 A 2 no
1 A 2 no
2 A 2 yes
5 A yes
1 B 1 no
1 B 1 no
1 B 1 no
3 B 1 yes
1 B 2 no
1 B 2 no
2 B 2 yes
5 B yes
Any idea??
Christoph