Show me the name of all movies.
select title from movie
What about their ratings?
select t1.title, t2.stars from movie as t1 join rating as t2 on t1.mid = t2.mid
Only show those with a rating of 4 or 5.
select t1.title, t2.stars from movie as t1 join rating as t2 on t1.mid = t2.mid where t2.stars >= 4
Give me all years that have any of those movies in the order of year.
select distinct year from movie as t1 join rating as t2 on t1.mid = t2.mid where t2.stars >= 4 order by t1.year