Context: CREATE TABLE film (title VARCHAR, film_id VARCHAR, rental_rate VARCHAR); CREATE TABLE inventory (film_id VARCHAR); CREATE TABLE film (title VARCHAR, film_id VARCHAR)
Question: Which film is rented at a fee of 0.99 and has less than 3 in the inventory? List the film title and id.
Answer: SELECT title, film_id FROM film WHERE rental_rate = 0.99 INTERSECT SELECT T1.title, T1.film_id FROM film AS T1 JOIN inventory AS T2 ON T1.film_id = T2.film_id GROUP BY T1.film_id HAVING COUNT(*) < 3