15. Advanced SQL

Sections
Calculating Running Statistics
Generating Sequences
Finding Sequences, Runs, and Regions
Limiting the Number of Rows Returned
Assigning Ranks
Calculating a Trimmed Mean
Picking Random Rows
Handling Duplicates
Creating a Telephone List
Retrieving Metadata
Working with Dates
Calculating a Median
Finding Extreme Values
Changing Running Statistics Midstream
Pivoting Results
Working with Hierarchies

This bonus chapter, included with only the print and ebook editions of SQL Run, describes how to solve common problems with SQL programs that