I'm having difficulty pinning down the proper syntax to get a total I need from Oracle 11g. I need to produce a total based on values in column 2, independent of the values in column 1. I've tried several types of rollup, cube, grouping sets, but I keep getting totals for each grade level (values in column 1).
Here is the 'group by' without any subtotaling:
... sql select statement ...
...
GROUP BY grade, inc_count
ORDER BY grade
which produces
9 714
10 550
11 445
12 296
And here is my goal output:
9 714
10 550
11 445
12 296
2005
Which permutation of rollup/group sets/or something else will get me to my goal output?