Welcome to the Treehouse Community
Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community!
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.
Start your free trial

Makayi Lendo
9,033 PointsSQL calculating, aggregating...code challenge 3 of 3 stage 7
I am stuck on code challenge task 3 of 3. I cannot get it right , here's my code:
SELECT title, IFNULL(AVG(score),0) AS average FROM reviews LEFT OUTER JOIN movies ON reviews.movie_id = movies.id GROUP BY movie_id HAVING average > 2;
2 Answers

Makayi Lendo
9,033 PointsI got it! The code stays the except that you have to a RIGHT OUTER JOIN instead of LEFT OUTER JOIN

Andreas cormack
Python Web Development Techdegree Graduate 33,011 PointsI had a similar problem. try this less than two.
SELECT title, IFNULL(AVG(score),0) AS average FROM reviews LEFT OUTER JOIN movies ON reviews.movie_id = movies.id GROUP BY movie_id HAVING average < 2;

Travis Johnston
12,653 PointsKept having trouble with this challenge. Your code is similar but mine only worked if I did a RIGHT OUTER JOIN