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 SQL Reporting by Example!
You have completed SQL Reporting by Example!
Preview
Which room has the largest capacity?
This video doesn't have any notes.
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
To figure out which room has the largest
capacity, instead of using the sum or
0:00
count aggregate methods,
we'll be using the MAX method.
0:02
So let's SELECT the MAX(CAPACITY) FROM
the ROOMS table.
0:06
Then you Shift+Enter, and
it looks like the MAX(CAPACITY) is 40.
0:14
And to figure out which room this is,
we can just add in the ID column.
0:18
And if we run it now,
it looks like it's room 19.
0:23
Also, another cool thing you can do
is you can always just SELECT *.
0:27
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