December 2014
Intermediate to advanced
852 pages
17h 57m
English
Reports, also known as OLAP queries, mix unlike things into the same row or the same table. This is done for reporting rather than traditional queries.
Keywords
Online transaction processing
GROUP BY
OLAP
ROLLUP
CUBE
GROUPING(< column reference >) function
GROUPING SET
OVER()
ORDER BY
PARTITION BY
< null ordering >
ROWS
RANGE
UNBOUNDED PRECEDING
CURRENT ROW
BETWEEN
EXCLUDE
Ordinal functions
ROW_NUMBER()
RANK()
DENSE_RANK()
PERCENT_RANK()
CUME_DIST
LEAD
LAG
FIRST
LAST
FIRST_VALUE
LAST_VALUE
Most sql programmers work with OLTP (online transaction processing) databases and write simple, one-level aggregations. This chapter reviews how the usual GROUP BY clause works. The result set is partitioned ...
Read now
Unlock full access