摘要:
A method, apparatus, and article of manufacture for optimizing SQL queries in a relational database management system involving aggregate and grouping functions. A local aggregation operation is performed on one or more processors of a massively parallel processor (MPP) computer system, wherein rows of the table that are local to each processor are locally aggregated to create one or more aggregate result rows. The aggregate result rows created by each of the local aggregation operations are then re-distributed to one or more processors and coalesced into a global aggregate result row by a global aggregation operation.