Heads up! To view this whole video, sign in with your Courses account or enroll in your free 7-day trial. Sign In Enroll
- Counting Results 4:41
- Counting Results 2 objectives
- Counting Groups of Rows 2:21
- Counting Groups 2 objectives
- Getting the Grand Total 5:31
- Summing Values 1 objective
- Calculating Averages 2:01
- Averaging Values 1 objective
- Getting Minimum and Maximum Values 2:08
- Calculating the Minimum and Maximum Values 1 objective
- Performing Math on Numeric Types 4:35
- Performing Math 1 objective
- Practice Session 2:31
- Review: Aggregate and Numeric Functions 5 questions

- 2x 2x
- 1.75x 1.75x
- 1.5x 1.5x
- 1.25x 1.25x
- 1.1x 1.1x
- 1x 1x
- 0.75x 0.75x
- 0.5x 0.5x
Calculating grand totals are handy for answering questions like "How much was spent today on the site?" and "What are the total number of goals scored by a particular team?"
To total up numeric columns use the SUM()
function.
SELECT SUM(<numeric column) FROM <table>;
SELECT SUM(<numeric column) AS <alias> FROM <table>
GROUP BY <another column>
HAVING <alias> <operator> <value>;
Cheat Sheets
Related Discussions
Have questions about this video? Start a discussion with the community and Treehouse staff.
Sign up-
nicolaspeterson
8,569 Points3 Answers
-
A X
12,842 Points1 Answer
-
james white
78,399 Points5 Answers
View all discussions for this video
Related Discussions
Have questions about this video? Start a discussion with the community and Treehouse staff.
Sign up
You need to sign up for Treehouse in order to download course files.
Sign upYou need to sign up for Treehouse in order to set up Workspace
Sign up