Heads up! To view this whole video, sign in with your Courses account or enroll in your free 7-day trial. Sign In Enroll
Well done!
You have completed Reporting with SQL!
You have completed Reporting with SQL!
Preview
Let's practice the new keywords, operators and functions you've learned in this section.
Cheat Sheets
Related Discussions
Have questions about this video? Start a discussion with the community and Treehouse staff.
Sign upRelated Discussions
Have questions about this video? Start a discussion with the community and Treehouse staff.
Sign up
We've covered a lot in this stage.
0:00
We've been introduced to new keywords,
functions, and operators.
0:01
Let's quickly review them and
0:06
then you can practice them in this SQL
playground associated with this video.
0:08
Let's start with all
the functions you've learned.
0:12
[SOUND] We've used the COUNT
function to count the number
0:14
of rows depending on
the queries we've created.
0:18
Remember that when giving
a specific column name,
0:21
count won't include rows with null values.
0:24
Use a star or asterisk to get all rows.
0:27
The sum function is used to sum all
the numeric values in a column.
0:31
We use this to get various
totals from the orders table.
0:37
The average function is used to calculate
the average values in a given column.
0:41
The maximum and minimum functions are used
to compare all values in a column and
0:47
retrieve the minimum and maximum values.
0:52
Finally, we use the round function to
round values to a specific decimal place.
0:56
With all of these functions, you can use
all of them with all rows in the table or
1:01
a selection of the data you
define through a WHERE clause or
1:07
group in sets of rows together.
1:10
This takes us to
the keywords you've learned.
1:13
First, we saw the distinct
keyword in action.
1:16
This finds unique values in a column.
1:19
Then we use the group by to
perform a similar action.
1:22
Find unique values.
1:25
But instead of discarding duplicates,
it grouped them together.
1:27
Once the results are grouped,
you can use the SQL functions to get
1:32
information about
the different groups of rows.
1:36
Finally, if you want to filter
based on aggregate information,
1:39
you can't use a where clause.
1:44
You have to use a having clause.
1:45
You were introduced to some new
operators by performing math
1:49
on columns of numeric data.
1:52
Addition, subtraction,
multiplication, and division.
1:55
Launch the SQL Playground now and you'll
find another practice session for you.
2:00
Familiarize yourself with
the database schema and
2:05
then proceed to answer questions
in each of the coding areas.
2:08
Once you're finished with this session,
there's another assessment.
2:15
This section of this course
has been pretty challenging.
2:19
And you've accomplished so much.
2:22
You're growing.
2:23
Keep it up.
2:24
In the next section, we'll take a look
at some more powerful functions,
2:25
like calculating and formatting dates.
2:28
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