SQL exercises on AGGREGATION AND GROUPING

This page lists the 8 exercises about Aggregation and grouping in SQL on our website:

Software: SQL
Version: Any version of SQL Server
Topic: Aggregation and grouping
Level: Relatively easy
Course: Introduction to SQL
Exercise: Use grouping to show how many episodes each Doctor Who author wrote.

Go to exercise ...

Software: SQL
Version: Any version of SQL Server
Topic: Aggregation and grouping
Level: Relatively easy
Course: Introduction to SQL
Exercise: Use GROUP BY and COUNT to report on the number of events for each category.

Go to exercise ...

Software: SQL
Version: Any version of SQL Server
Topic: Aggregation and grouping
Level: Relatively easy
Course: Introduction to SQL
Exercise: Use COUNT, MAX and MIN to show statistics about the rows in the events table.

Go to exercise ...

Software: SQL
Version: Any version of SQL Server
Topic: Aggregation and grouping
Level: Average difficulty
Course: Introduction to SQL
Exercise: Use SELECT, FROM, WHERE, GROUP BY, HAVING and ORDER BY to list non-European busy countries.

Go to exercise ...

Software: SQL
Version: Any version of SQL Server
Topic: Aggregation and grouping
Level: Average difficulty
Course: Introduction to SQL
Exercise: Group by 2 fields and use HAVING clause to show popular combinations.

Go to exercise ...

Software: SQL
Version: Any version of SQL Server
Topic: Aggregation and grouping
Level: Harder than average
Course: Introduction to SQL
Exercise: Use lots of grouping and criteria to list out year/doctor episode counts.

Go to exercise ...

Software: SQL
Version: Any version of SQL Server
Topic: Aggregation and grouping
Level: Harder than average
Course: Introduction to SQL
Exercise: Combine CAST, AVG, COUNT, LEN, UPPER and LEFT to show the average length of event names by category initial.

Go to exercise ...

Software: SQL
Version: Any version of SQL Server
Topic: Aggregation and grouping
Level: Harder than average
Course: Introduction to SQL
Exercise: Use a complex CASE statement to show the number of events for each century, including the CUBE function.

Go to exercise ...

You can search our full list of SQL exercises here, or why not have a look at our other SQL training resources?

This page has 0 threads Add post