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, rental_date, return_date, payment_date, rental_rate, (rental_rate - amount) AS lateness_penalty, amount 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 payment p ON r.rental_id = p.rental_id INNER JOIN customer c ON p.customer_id = c.customer_id AND c.first_name = 'DOROTHY' AND c.last_name = 'TAYLOR' WHERE rental_date LIKE'2005-08%' UNION SELECT 'Total' AS f.title, null AS rental_date, null AS return_date, null AS payment_date, rental_rate, (rental_rate - amount) AS lateness_penalty, amount ; show status like 'Last_query_cost';

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

Copy Clear