Difference between revisions of "SQL Aggregate Functions"
From Lianjapedia
Yvonne.milne (Talk | contribs) |
Yvonne.milne (Talk | contribs) |
||
| (3 intermediate revisions by 2 users not shown) | |||
| Line 9: | Line 9: | ||
| − | {| class="wikitable" | + | {| class="wikitable" width="100%" |
!Aggregate Function||Description | !Aggregate Function||Description | ||
|- | |- | ||
| − | |[[AVG()]]||The AVG() Aggregate Function returns the average value for the specified numeric column or expression. | + | |valign="top"|[[AVG()]]||The AVG() Aggregate Function returns the average value for the specified numeric column or expression. |
|- | |- | ||
| − | |[[COUNT()]]||The COUNT() Aggregate Function returns a row count. | + | |valign="top"|[[COUNT()]]||The COUNT() Aggregate Function returns a row count. |
|- | |- | ||
| − | |[[SQL MAX()|MAX()]]||The MAX() Aggregate Function returns the maximum value for the specified numeric or date column or expression. | + | |valign="top"|[[SQL MAX()|MAX()]]||The MAX() Aggregate Function returns the maximum value for the specified numeric or date column or expression. |
|- | |- | ||
| − | |[[SQL MIN()|MIN()]]||The MIN() Aggregate Function returns the minimum value for the specified numeric or date column or expression. | + | |valign="top"|[[SQL MIN()|MIN()]]||The MIN() Aggregate Function returns the minimum value for the specified numeric or date column or expression. |
|- | |- | ||
| − | |[[SUM()]]||The SUM() Aggregate Function returns the sum of the specified numeric column or expression. | + | |valign="top"|[[SUM()]]||The SUM() Aggregate Function returns the sum of the specified numeric column or expression. |
|- | |- | ||
|} | |} | ||
| Line 27: | Line 27: | ||
[[Category:SQL|Aggregate Functions]] | [[Category:SQL|Aggregate Functions]] | ||
[[Category:Functions]] | [[Category:Functions]] | ||
| + | [[Category:SQL Functions]] | ||
Latest revision as of 07:58, 27 October 2014
Purpose
Aggregate Functions
See Also
AVG(), COUNT(), MAX(), MIN(), SELECT, SUM()
Description
Aggregate Functions, also known as Group Functions, operate on a group of rows rather than individual rows. They return a single result row.
| Aggregate Function | Description |
|---|---|
| AVG() | The AVG() Aggregate Function returns the average value for the specified numeric column or expression. |
| COUNT() | The COUNT() Aggregate Function returns a row count. |
| MAX() | The MAX() Aggregate Function returns the maximum value for the specified numeric or date column or expression. |
| MIN() | The MIN() Aggregate Function returns the minimum value for the specified numeric or date column or expression. |
| SUM() | The SUM() Aggregate Function returns the sum of the specified numeric column or expression. |