Deals Of The Week - hours only!Up to 80% off on all courses and bundles.-Close
Introduction
Simple OVER()
PARTITION BY
Ranking functions
Window Frames
Analytic Functions
PARTITION BY ORDER BY
27. PARTITION BY ORDER BY – Exercise 2
Order of Evaluation
Finished!

Instruction

Super! Let's move on.

Exercise

For each review, show the following information: its Id, the movie Title, the movie Rating, and the previous Rating given by any customer to the same movie. Sort by the Id of the review. Name the new column PreviousRating.

Stuck? Here's a hint!

INNER JOIN tables Review and Movie. Use:

OVER(PARTITION BY Review.MovieId ORDER BY Review.Id ASC)