31.2. OLAP Functionality

While OLAP systems have the ability to answer “who” and “what” questions, it is their ability to answer “what if” that sets them apart from other BI (business intelligence) tools. Leading RDBMS products, such as DB2 and Oracle, currently offer core OLAP-centric SQL functions, including categories such as ranking, numbering, and grouping. In fact, DB2 added extensions to its optimizer to identify a Star Schema and build a special execution plan for it.

When specifying an OLAP function, a window defines the rows over which the function is applied, and in what order. When used with a column function, the applicable rows can be further refined, relative to the current row, as either a range or a number of rows preceding ...

Get Joe Celko's SQL for Smarties, 3rd Edition now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.