SQL Set Functions
Part of the SQL For Dummies Cheat Sheet
The SQL set functions give you a quick answer to questions you may have about the characteristics of your data as a whole. How many rows does a table have? What is the highest value in the table? What is the lowest? These are the kinds of questions that the SQL set functions can answer for you.
|COUNT||Returns the number of rows in the specified table|
|MAX||Returns the maximum value that occurs in the specified table|
|MIN||Returns the minimum value that occurs in the specified table|
|SUM||Adds up the values in a specified column|
|AVG||Returns the average of all the values in the specified column|