Hugo Kornelis takes us through the concept of aggregate functions:
SQL Server currently supports three operators that can compute aggregations: Hash Match, Stream Aggregate, and Window Aggregate. These operators all use the same basic principle of maintaining internal counters as rows are processed, so that the final value of those internal counters is the expected value.
Read on to see the full list, as well as how they operate.