12 lines
418 B
MySQL
12 lines
418 B
MySQL
|
/*48. Write a query in SQL to find the highest-rated Mystery movie, and report the title, year, and rating. */
|
||
|
SELECT mov_title, mov_year, rev_stars
|
||
|
FROM movie
|
||
|
NATURAL JOIN movie_genres
|
||
|
NATURAL JOIN genres
|
||
|
NATURAL JOIN rating
|
||
|
WHERE gen_title = 'Mystery' AND rev_stars >= ALL (
|
||
|
SELECT rev_stars
|
||
|
FROM rating
|
||
|
NATURAL JOIN movie_genres
|
||
|
NATURAL JOIN genres
|
||
|
WHERE gen_title = 'Mystery');
|