Oracle PL/SQL Subtotal Operators
There are times when we need not just the total value for the column, but subtotal values depending on different column values. Oracle supports subtotal operators through the three key operators they are CUBE, ROLLUP, and GROUPING SETS. Below are examples of each one and how best to use them.