The GROUP BY Clause

The GROUP BY clause is intimately connected to aggregates. In fact, GROUP BY doesn't really have much use without aggregate functions: it divides a table into sets of rows, and aggregate functions produce summary values for each set. These values are called vector aggregates. (A scalar aggregate is a single value produced by an aggregate function as discussed in the previous chapter.) Figure 6.1 shows examples of scalar and vector aggregate queries.

Figure 6.1. Scalar and Vector Aggregates


..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
18.116.63.5