SQL queries containing GROUP BY and aggre-gation occur frequently in decision support applications. Grouping with aggregation is typically done by rst sorting the input and then performing the aggregation as part of the output phase of the sort. The most widely used external sorting algorithm is merge sort, consisting of a run formation phase followed by a (single) merge pass. The amount of dat...