On January 21th at 14:15 UTC , progression through exercises will be unavailable for 10 minutes due to a planned maintenance break.
Deals Of The Week - hours only!Up to 80% off on all courses and bundles.-Close


Here is another one!


Select the name, rating, city of origin, and the total number of concerts it held in Ukraine for each orchestra that originated in Germany. Name the last column count.

Stuck? Here's a hint!

First, select the name, rating, and city of origin for each orchestra from Germany (no need for a subquery here). Then, add a correlated subquery in the SELECT clause, which will count the number of concerts held in Ukraine by the given orchestra.

An example of a correlated subquery in SELECT looks like this:

   (SELECT AVG(age) FROM cats c2 WHERE c2.name = c1.name)
FROM cats c1

This query finds the name of the cat together with the average age of all cats with the same name.