Hi! Could we please enable some services and cookies to improve your experience and our website?

SQLize | PHPize | SQLtest

Online Sandbox for SQL and PHP: Write, Run, Test, and Share SQL Queries and PHP Code

A A A
Login    Share code      Blog   FAQ
Copy Format Clear
select f.title, f.rating from film f inner join inventory i on f.film_id=i.film_id inner join rental r on i.inventory_id=r.inventory_id inner join customer c on r.customer_id=c.customer_id where c.first_name='KATIE' and c.last_name='ELLIOTT' order by CASE WHEN f.rating='R' THEN 0 ELSE 1 END, f.title asc; ; show status like 'Last_query_cost';

Stuck with a problem? Got Error? Ask AI support!

Copy Clear