🙏 We need your help! SQLtest.online has no ads and lives only on donations. Even a small amount helps. Donate now →
SQL code copied to buffer
Task 23:

Repeat Rentals

MySQL
Find the customers who have rented the same film more when one time. Present the result as table with next columns: first_name, last_name - client's name and surname, title - film's title, first_rental_date, last_rental_date - the film first and last rental dates rentals_count - how many times the film was rented by client.
Sort the table by movie title, then by customer's first and last name.
Expected result Columns: 6 · Rows: 212
first_name last_name title first_rental_date last_rental_date rentals_count

Sample rows open after wrong checks: 0 of 3

Write your query below and click "Check it!". Tables are described in the right pane.

Tutorial

By checking a query, you agree that it is stored without your account details and may be included in anonymized datasets, including for AI training. Learn more

The query result will appear here. Ctrl+Enter - Run query