Welcome to the Treehouse Community
Looking to learn something new?
Database Foundations : Stage 7, Step 4, Grouping, Joining and Cleaning Up :: Code Challenge : 1 of 3
The challenge is :
Group all reviews by "movie_id" and get the average "score" and alias it as "average".
My sql query for the same :
select movie_id, avg(score) AS average from reviews group by movie_id;
I am getting a valid output with the error "Oops! There is something wrong with your query"
I can't preview what this 'something' is and I am unable to proceed to the next challenge. Please help me!
The link to the challenge is : http://teamtreehouse.com/library/grouping-joining-and-cleaning-up
SERGIO RODRIGUEZ17,532 Points
SELECT avg(score) AS average FROM reviews GROUP BY movie_id;
Hope this helps!