Chapter 7. Advanced Grouping

Jared Still

The GROUP BY clause is a venerable member of the SQL statement family. After learning basic SELECT statements, it is one of first specialized parts of SQL that many practitioners cut their teeth on when learning to create aggregations from raw data and transform that data into useful information.

Before I get too deeply into the use of GROUP BY, this would be a good time provide some information about the test environment. All SQL in this chapter was prepared using the Oracle 64 bit version on Windows 7. The database account I used has DBA privileges. Using an account with DBA privileges simplifies the use of dbms_xplan.display_cursor, using data from other accounts, and selecting data from system ...

Get Pro Oracle SQL now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.