group by

The group by statement groups rows that have the same values into summary rows. It is often used with aggregate functions (COUNT, MAX, MIN, SUM, AVG) to group the result-set by one or more columns.
<pre><code>
select title, count(*) from titles group by title having count(*) > 1000;
</code></pre>