id
int64
0
9.43k
db_id
stringclasses
69 values
schema
stringclasses
69 values
question
stringlengths
24
325
output
stringlengths
23
804
evidence
stringlengths
0
673
filtered_schema
listlengths
0
16
9,200
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
List the actors' IDs who have "KILMER" as last name.
SELECT actor_id FROM actor WHERE last_name = 'KILMER'
[ "actor.actor_id", "actor.last_name" ]
9,201
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
List down the films titles with the lowest replacement cost under the general audiences rating.
SELECT title FROM film WHERE replacement_cost = ( SELECT MIN(replacement_cost) FROM film )
lowest replacement cost refers to Min(replacement_cost); under general audience rating refers to rating = G
[ "film.replacement_cost", "film.title" ]
9,202
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
Among the films with the longest duration, list any five title with their descriptions and special features.
SELECT title, description, special_features FROM film WHERE length = ( SELECT MAX(length) FROM film ) LIMIT 5
longest duration of film refers to Max(length)
[ "film.description", "film.length", "film.special_features", "film.title" ]
9,203
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
How many films rented on 26th May, 2005 were returned on 30th May, 2005?
SELECT COUNT(DISTINCT rental_id) FROM rental WHERE date(rental_date) BETWEEN '2005-05-26' AND '2005-05-30'
rented on 26th May 2005 refers to rental_date = '2005-05-26'; return on 30th May, 2005 refers to return_date = '2005-05-30'; number of rented film refers to Count (rental_id)
[ "rental.rental_date", "rental.rental_id" ]
9,204
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
Calculate the average payment amount per customer.
SELECT AVG(amount) FROM payment GROUP BY customer_id
average payment refers to AVG(amount)
[ "payment.amount", "payment.customer_id" ]
9,205
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
What is the name and email of the staff in store ID 2?
SELECT first_name, last_name, email FROM staff WHERE store_id = 2
name refers to first_name, last_name
[ "staff.email", "staff.first_name", "staff.last_name", "staff.store_id" ]
9,206
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
How many percent of customers were inactive?
SELECT CAST(SUM(IIF(active = 0, 1, 0)) AS REAL) * 100 / COUNT(customer_id) FROM customer
inactive refers to active = 0; percent = Divide (Count (customer_id where active = 0), Count(customer_id)) * 100
[ "customer.active", "customer.customer_id" ]
9,207
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
What is the description and film title of ID 996?
SELECT description, title FROM film_text WHERE film_id = 996
ID 996 refers to film_id = 996
[ "film_text.description", "film_text.film_id", "film_text.title" ]
9,208
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
Calculate customers' total payment amount in August, 2005.
SELECT SUM(amount) FROM payment WHERE SUBSTR(payment_date, 1, 7) = '2005-08'
in August 2005 refers to payment_date like '2005-08%'; total payment amount refers to Sum(amount)
[ "payment.amount", "payment.payment_date" ]
9,209
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
List down the film titles performed by Emily Dee.
SELECT T3.title FROM actor AS T1 INNER JOIN film_actor AS T2 ON T1.actor_id = T2.actor_id INNER JOIN film AS T3 ON T2.film_id = T3.film_id WHERE T1.first_name = 'Emily' AND T1.last_name = 'Dee'
[ "actor.actor_id", "actor.first_name", "actor.last_name", "film.film_id", "film.title", "film_actor.actor_id", "film_actor.film_id" ]
9,210
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
List down the actors' full names who performed in "CHOCOLATE DUCK" film.
SELECT T3.first_name, T3.last_name FROM film_actor AS T1 INNER JOIN film AS T2 ON T1.film_id = T2.film_id INNER JOIN actor AS T3 ON T1.actor_id = T3.actor_id WHERE T2.title = 'CHOCOLATE DUCK'
"CHOCOLATE DUCK" is the title of film; full name refers to first_name, last_name
[ "actor.actor_id", "actor.first_name", "actor.last_name", "film.film_id", "film.title", "film_actor.actor_id", "film_actor.film_id" ]
9,211
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
How many films in the horror category were included in PG-13-rated?
SELECT COUNT(T1.film_id) FROM film AS T1 INNER JOIN film_category AS T2 ON T1.film_id = T2.film_id INNER JOIN category AS T3 ON T2.category_id = T3.category_id WHERE T3.name = 'Horror' AND T1.rating = 'PG-13'
"Horror" is the name of category; PG-13 rated refers to rating = 'PG-13'
[ "category.category_id", "category.name", "film.film_id", "film.rating", "film_category.category_id", "film_category.film_id" ]
9,212
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
Distinguish the films performed by Judy Dean according to category.
SELECT T5.name FROM actor AS T1 INNER JOIN film_actor AS T2 ON T1.actor_id = T2.actor_id INNER JOIN film AS T3 ON T2.film_id = T3.film_id INNER JOIN film_category AS T4 ON T2.film_id = T4.film_id INNER JOIN category AS T5 ON T4.category_id = T5.category_id WHERE T1.first_name = 'Judy' AND T1.last_name = 'Dean'
films performed refers to film
[ "actor.actor_id", "actor.first_name", "actor.last_name", "category.category_id", "category.name", "film.film_id", "film_actor.actor_id", "film_actor.film_id", "film_category.category_id", "film_category.film_id" ]
9,213
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
Write down any five film names under the documentary category.
SELECT T1.title FROM film AS T1 INNER JOIN film_category AS T2 ON T1.film_id = T2.film_id INNER JOIN category AS T3 ON T2.category_id = T3.category_id WHERE T3.name = 'Documentary' LIMIT 5
"Documentary" is the name of category; film name refers to title
[ "category.category_id", "category.name", "film.film_id", "film.title", "film_category.category_id", "film_category.film_id" ]
9,214
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
Mention the language of Untouchables Sunrise film and calculate its rental cost per day.
SELECT T2.name, T1.replacement_cost / T1.rental_duration AS cost FROM film AS T1 INNER JOIN language AS T2 ON T1.language_id = T2.language_id WHERE T1.title = 'UNTOUCHABLES SUNRISE'
"UNTOUCHABLES SUNRISE" is the title of film; language refers to name; rental cost per day = Divide (rental_cost, rental_duration)
[ "film.language_id", "film.rental_duration", "film.replacement_cost", "film.title", "language.language_id", "language.name" ]
9,215
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
List the films' titles which were rented on 24th May,2005.
SELECT T1.title FROM film AS T1 INNER JOIN inventory AS T2 ON T1.film_id = T2.film_id INNER JOIN rental AS T3 ON T2.inventory_id = T3.inventory_id WHERE SUBSTR(T3.rental_date, 1, 10) = '2005-05-24'
rented on 24th May 2005 refers to rental_date = '2005-05-24%'
[ "film.film_id", "film.title", "inventory.film_id", "inventory.inventory_id", "rental.inventory_id", "rental.rental_date" ]
9,216
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
List the films' titles which were rented by Brian Wyman in July, 2005.
SELECT T4.title FROM customer AS T1 INNER JOIN rental AS T2 ON T1.customer_id = T2.customer_id INNER JOIN inventory AS T3 ON T2.inventory_id = T3.inventory_id INNER JOIN film AS T4 ON T3.film_id = T4.film_id WHERE T1.first_name = 'BRIAN' AND T1.last_name = 'WYMAN' AND STRFTIME('%Y', T2.rental_date) = '2005' AND STRFTIM...
rented in July 2005 refers to year (rental_date) = 2005 and month (rental_date) = 7
[ "customer.customer_id", "customer.first_name", "customer.last_name", "film.film_id", "film.title", "inventory.film_id", "inventory.inventory_id", "rental.customer_id", "rental.inventory_id", "rental.rental_date" ]
9,217
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
Write down the inventories' IDs and actors' names of "STREETCAR INTENTIONS".
SELECT T4.inventory_id, T1.first_name, T1.last_name FROM actor AS T1 INNER JOIN film_actor AS T2 ON T1.actor_id = T2.actor_id INNER JOIN film AS T3 ON T2.film_id = T3.film_id INNER JOIN inventory AS T4 ON T2.film_id = T4.film_id WHERE T3.title = 'STREETCAR INTENTIONS'
"STREETCAR INTENTIONS" is the title of film; actor's names refers to first_name, last_name
[ "actor.actor_id", "actor.first_name", "actor.last_name", "film.film_id", "film.title", "film_actor.actor_id", "film_actor.film_id", "inventory.film_id", "inventory.inventory_id" ]
9,218
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
Among the films rented by Natalie Meyer, describe the titles and categories of the films which were rented in February 2006.
SELECT T3.title, T2.name FROM film_category AS T1 INNER JOIN category AS T2 ON T1.category_id = T2.category_id INNER JOIN film AS T3 ON T1.film_id = T3.film_id INNER JOIN inventory AS T4 ON T3.film_id = T4.film_id INNER JOIN customer AS T5 ON T4.store_id = T5.store_id INNER JOIN rental AS T6 ON T4.inventory_id = T6.inv...
category refers to name; rented in February 2006 refers to year(rental_date) = 2006 and month (rental_rate) = 2
[ "category.category_id", "category.name", "customer.first_name", "customer.last_name", "customer.store_id", "film.film_id", "film.rental_rate", "film.title", "film_category.category_id", "film_category.film_id", "inventory.film_id", "inventory.inventory_id", "inventory.store_id", "rental.in...
9,219
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
How many rental IDs belong to Eleanor Hunt?
SELECT COUNT(T1.rental_id) FROM rental AS T1 INNER JOIN customer AS T2 ON T1.customer_id = T2.customer_id WHERE T2.first_name = 'Eleanor' AND T2.last_name = 'Hunt'
'Eleanor Hunt' is the full name of a customer; full name refers to first_name, last_name
[ "customer.customer_id", "customer.first_name", "customer.last_name", "rental.customer_id", "rental.rental_id" ]
9,220
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
Describe the full names and cities of the customers who rented "DREAM PICKUP".
SELECT T4.first_name, T4.last_name, T6.city FROM film AS T1 INNER JOIN inventory AS T2 ON T1.film_id = T2.film_id INNER JOIN rental AS T3 ON T2.inventory_id = T3.inventory_id INNER JOIN customer AS T4 ON T3.customer_id = T4.customer_id INNER JOIN address AS T5 ON T4.address_id = T5.address_id INNER JOIN city AS T6 ON T...
full name refers to first_name, last_name; 'DREAM PICKUP' is a title of film
[ "address.address_id", "address.city_id", "city.city", "city.city_id", "customer.address_id", "customer.customer_id", "customer.first_name", "customer.last_name", "film.film_id", "film.title", "inventory.film_id", "inventory.inventory_id", "rental.customer_id", "rental.inventory_id" ]
9,221
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
Calculate how many percent of customers were located in India.
SELECT CAST(SUM(IIF(T1.country = 'India', 1, 0)) AS REAL) * 100 / COUNT(T4.customer_id) FROM country AS T1 INNER JOIN city AS T2 ON T1.country_id = T2.country_id INNER JOIN address AS T3 ON T2.city_id = T3.city_id INNER JOIN customer AS T4 ON T3.address_id = T4.address_id
'India' is a country; calculation = DIVIDE(SUM(country = 'India'), COUNT(customer_id)) * 100
[ "address.address_id", "address.city_id", "city.city_id", "city.country_id", "country.country", "country.country_id", "customer.address_id", "customer.customer_id" ]
9,222
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
How much percentage of the film did Mary Keitel perform more than Angela Witherspoon?
SELECT CAST((SUM(IIF(T1.first_name = 'ANGELA' AND T1.last_name = 'WITHERSPOON', 1, 0)) - SUM(IIF(T1.first_name = 'MARY' AND T1.last_name = 'KEITEL', 1, 0))) AS REAL) * 100 / SUM(IIF(T1.first_name = 'MARY' AND T1.last_name = 'KEITEL', 1, 0)) FROM actor AS T1 INNER JOIN film_actor AS T2 ON T1.actor_id = T2.actor_id
'Mary Keitel' AND 'Angela Witherspoon' are full name of actors; full name refers to FirstName, LastName; calculation = DIVIDE(SUBTRACT(SUM('Mary Keitel'), SUM('Angela Witherspoon')), SUM('Angela Witherspoon')) * 100
[ "actor.actor_id", "actor.first_name", "actor.last_name", "film_actor.actor_id" ]
9,223
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
Provide the email, address, city, and country of the customer Lillie Kim.
SELECT T1.email, T2.address, T3.city, T4.country FROM customer AS T1 INNER JOIN address AS T2 ON T1.address_id = T2.address_id INNER JOIN city AS T3 ON T2.city_id = T3.city_id INNER JOIN country AS T4 ON T3.country_id = T4.country_id WHERE T1.first_name = 'Lillie' AND T1.last_name = 'Kim'
'Lillie Kim' is the full name of a customer; full name refers to first_name, last_name
[ "address.address", "address.address_id", "address.city_id", "city.city", "city.city_id", "city.country_id", "country.country", "country.country_id", "customer.address_id", "customer.email", "customer.first_name", "customer.last_name" ]
9,224
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
Provide any 5 customers' full names who have rented from Mike Hillyer.
SELECT T3.first_name, T3.last_name FROM staff AS T1 INNER JOIN address AS T2 ON T1.address_id = T2.address_id INNER JOIN customer AS T3 ON T2.address_id = T3.address_id WHERE T1.first_name = 'Mike' AND T1.last_name = 'Hillyer' LIMIT 5
full name refers to first_name, last_name; 'Mike Hillyer' is a full name of a staff;
[ "address.address_id", "customer.address_id", "customer.first_name", "customer.last_name", "staff.address_id", "staff.first_name", "staff.last_name" ]
9,225
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
Calculate the total payment amount by Diane Collins.
SELECT SUM(T2.amount) FROM customer AS T1 INNER JOIN payment AS T2 ON T1.customer_id = T2.customer_id WHERE T1.first_name = 'Diane' AND T1.last_name = 'Collins'
'Diane Collins' is a full name of a customer; full name refers to first_name, last_name
[ "customer.customer_id", "customer.first_name", "customer.last_name", "payment.amount", "payment.customer_id" ]
9,226
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
Provide the full names and emails of customers whose payments were greater than 70% of the average.
SELECT DISTINCT T2.first_name, T2.last_name, T2.email FROM payment AS T1 INNER JOIN customer AS T2 ON T1.customer_id = T2.customer_id INNER JOIN address AS T3 ON T2.address_id = T3.address_id WHERE T1.amount > ( SELECT AVG(amount) FROM payment ) * 0.7
full name refers to first_name, last_name; average payment refers to AVG(amount); payments were greater than 70% of the average refers to amount > (AVG(amount) MULTIPLY 0.7)
[ "address.address_id", "customer.address_id", "customer.customer_id", "customer.email", "customer.first_name", "customer.last_name", "payment.amount", "payment.customer_id" ]
9,227
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
How many films have a rental rate of 0.99?
SELECT COUNT(film_id) FROM film WHERE rental_rate = 0.99
[ "film.film_id", "film.rental_rate" ]
9,228
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
Among the customers with customer ID of 100 and below, how many of them have Thomas as their last name?
SELECT COUNT(customer_id) FROM customer WHERE last_name = 'Thomas' AND customer_id < 100
customer ID of 100 and below refers to customer_id < 100
[ "customer.customer_id", "customer.last_name" ]
9,229
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
List the actor's last name that starred the film with the description of "A Thoughtful Drama of a Composer And a Feminist who must Meet a Secret Agent in The Canadian Rockies".
SELECT T1.last_name FROM actor AS T1 INNER JOIN film_actor AS T2 ON T1.actor_id = T2.actor_id INNER JOIN film AS T3 ON T2.film_id = T3.film_id WHERE T3.description = 'A Thoughtful Drama of a Composer And a Feminist who must Meet a Secret Agent in The Canadian Rockies'
[ "actor.actor_id", "actor.last_name", "film.description", "film.film_id", "film_actor.actor_id", "film_actor.film_id" ]
9,230
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
Give the title of the film starred by Liza Bergman with the highest replacement cost.
SELECT T3.title FROM actor AS T1 INNER JOIN film_actor AS T2 ON T1.actor_id = T2.actor_id INNER JOIN film AS T3 ON T2.film_id = T3.film_id WHERE T1.first_name = 'Liza' AND T1.last_name = 'Bergman' ORDER BY replacement_cost DESC LIMIT 1
Liza Bergman' is a full name; full name refers to first_name, last_name; highest replacement cost refers to MAX(replacement_cost)
[ "actor.actor_id", "actor.first_name", "actor.last_name", "film.film_id", "film.title", "film_actor.actor_id", "film_actor.film_id" ]
9,231
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
Among films with store ID of 2, list the title of films with the highest rental rate.
SELECT T1.title FROM film AS T1 INNER JOIN inventory AS T2 ON T1.film_id = T2.film_id WHERE T2.store_id = 2 ORDER BY rental_rate DESC LIMIT 1
highest rental rate refers to MAX(rental_rate)
[ "film.film_id", "film.title", "inventory.film_id", "inventory.store_id" ]
9,232
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
Among the films starred by Angelina Astaire, what is the title of the film with a replacement cost of 27.99?
SELECT T3.title FROM actor AS T1 INNER JOIN film_actor AS T2 ON T1.actor_id = T2.actor_id INNER JOIN film AS T3 ON T2.film_id = T3.film_id WHERE T1.first_name = 'Angelina' AND T1.last_name = 'Astaire' AND T3.replacement_cost = 27.99
Angelina Astaire' is a full name of an actor; full name refers to first_name, last_name
[ "actor.actor_id", "actor.first_name", "actor.last_name", "film.film_id", "film.replacement_cost", "film.title", "film_actor.actor_id", "film_actor.film_id" ]
9,233
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
List the inventory ID of the film titled "African Egg".
SELECT T2.inventory_id FROM film AS T1 INNER JOIN inventory AS T2 ON T1.film_id = T2.film_id WHERE T1.title = 'African Egg'
'African Egg' is a title of a film
[ "film.film_id", "film.title", "inventory.film_id", "inventory.inventory_id" ]
9,234
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
In films with a length duration of 113 minutes, how many of the films are starred by Kirk Jovovich?
SELECT COUNT(T1.actor_id) FROM actor AS T1 INNER JOIN film_actor AS T2 ON T1.actor_id = T2.actor_id INNER JOIN film AS T3 ON T2.film_id = T3.film_id WHERE T3.length = 113 AND T1.first_name = 'Kirk' AND T1.last_name = 'Jovovich'
length duration of 113 minutes refers to length = 113; 'Kirk Jovovich' is a full name of an actor; full name refers to first_name, last_name
[ "actor.actor_id", "actor.first_name", "actor.last_name", "film.film_id", "film.length", "film_actor.actor_id", "film_actor.film_id" ]
9,235
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
In the film with an inventory ID between 20 to 60, how many of the films have a G rating?
SELECT COUNT(T1.film_id) FROM film AS T1 INNER JOIN inventory AS T2 ON T1.film_id = T2.film_id WHERE T2.inventory_id BETWEEN 20 AND 60 AND T1.rating = 'G'
G rating refers to rating = 'G'
[ "film.film_id", "film.rating", "inventory.film_id", "inventory.inventory_id" ]
9,236
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
Among films with a rental rate of 4.99, what is the total number of films starred by Bob Fawcett?
SELECT COUNT(T1.actor_id) FROM actor AS T1 INNER JOIN film_actor AS T2 ON T1.actor_id = T2.actor_id INNER JOIN film AS T3 ON T2.film_id = T3.film_id WHERE T3.rental_rate = 4.99 AND T1.first_name = 'Bob' AND T1.last_name = 'Fawcett'
Bob Fawcett' is a full name of an actor; full name refers to first_name, last_name
[ "actor.actor_id", "actor.first_name", "actor.last_name", "film.film_id", "film.rental_rate", "film_actor.actor_id", "film_actor.film_id" ]
9,237
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
What is the inventory ID of the films starred by Russell Close with a duration between 110 to 150 minutes?
SELECT T4.inventory_id FROM actor AS T1 INNER JOIN film_actor AS T2 ON T1.actor_id = T2.actor_id INNER JOIN film AS T3 ON T2.film_id = T3.film_id INNER JOIN inventory AS T4 ON T3.film_id = T4.film_id WHERE T3.length BETWEEN 110 AND 150 AND T1.first_name = 'Russell' AND T1.last_name = 'Close'
'Russell Close' is a full name of an actor; full name refers to first_name, last_name; duration between 110 to 150 minutes refers to length BETWEEN 110 AND 150
[ "actor.actor_id", "actor.first_name", "actor.last_name", "film.film_id", "film.length", "film_actor.actor_id", "film_actor.film_id", "inventory.film_id", "inventory.inventory_id" ]
9,238
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
What is the store and inventory ID of the film with the longest duration?
SELECT T2.store_id, T2.inventory_id FROM film AS T1 INNER JOIN inventory AS T2 ON T1.film_id = T2.film_id ORDER BY T1.length DESC LIMIT 1
the longest duration refers to MAX(length)
[ "film.film_id", "film.length", "inventory.film_id", "inventory.inventory_id", "inventory.store_id" ]
9,239
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
List the titles of the films starred by Elvis Marx.
SELECT T3.title FROM actor AS T1 INNER JOIN film_actor AS T2 ON T1.actor_id = T2.actor_id INNER JOIN film AS T3 ON T2.film_id = T3.film_id WHERE T3.length BETWEEN 110 AND 150 AND T1.first_name = 'Russell' AND T1.last_name = 'Close'
'Elvis Marx' is a full name of a film; full name refers to first_name, last_name
[ "actor.actor_id", "actor.first_name", "actor.last_name", "film.film_id", "film.length", "film.title", "film_actor.actor_id", "film_actor.film_id" ]
9,240
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
In films with rental rate of 4.99, list down the inventory ID of the films starred by Lucille Dee.
SELECT T4.inventory_id FROM actor AS T1 INNER JOIN film_actor AS T2 ON T1.actor_id = T2.actor_id INNER JOIN film AS T3 ON T2.film_id = T3.film_id INNER JOIN inventory AS T4 ON T3.film_id = T4.film_id WHERE T1.first_name = 'Lucille' AND T1.last_name = 'Dee' AND T3.rental_rate = 4.99
'Lucille Dee' is a full name of an actor; full name refers to first_name, last_name
[ "actor.actor_id", "actor.first_name", "actor.last_name", "film.film_id", "film.rental_rate", "film_actor.actor_id", "film_actor.film_id", "inventory.film_id", "inventory.inventory_id" ]
9,241
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
List the store ID of the films with a rental rate greater than the 60% of average rental rate of all listed films.
SELECT T2.store_id FROM film AS T1 INNER JOIN inventory AS T2 ON T1.film_id = T2.film_id WHERE T1.rental_rate > ( SELECT AVG(T1.rental_rate) * 0.6 FROM film AS T1 )
average rental rate of all listed films refers to AVG(rental_rate); rental rate greater than the 60% of average rental rate refers to rental_rate > (AVG(rental_rate)) MULTIPLY 0.6
[ "film.film_id", "film.rental_rate", "inventory.film_id", "inventory.store_id" ]
9,242
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
Among the films starred by Nick Wahlberg, what is the percentage of the films with G rating?
SELECT CAST(SUM(IIF(T3.rating = 'G', 1, 0)) AS REAL) / COUNT(T3.film_id) FROM actor AS T1 INNER JOIN film_actor AS T2 ON T1.actor_id = T2.actor_id INNER JOIN film AS T3 ON T2.film_id = T3.film_id WHERE T1.first_name = 'Elvis' AND T1.last_name = 'Marx'
'Nick Wahlberg' is a full name of an actor; full name refers to first_name, last_name; G rating refers to rating = 'G'; calculation = DIVIDE(SUM(rating = 'G'), SUM(rating)) * 100
[ "actor.actor_id", "actor.first_name", "actor.last_name", "film.film_id", "film.rating", "film_actor.actor_id", "film_actor.film_id" ]
9,243
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
List the address in Texas in the ascending order of city id.
SELECT address FROM address WHERE district = 'Texas' AND city_id = ( SELECT MIN(city_id) FROM address WHERE district = 'Texas' )
'Texas' is a district
[ "address.address", "address.city_id", "address.district" ]
9,244
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
Find the full name and email address of inactive customers whose record was created in 2006.
SELECT first_name, last_name, email FROM customer WHERE STRFTIME('%Y',create_date) = '2006' AND active = 0
full name refers to first_name, last_name; record created in 2006 refers to create_date = 2006; inactive customers refers to active = 0
[ "customer.active", "customer.create_date", "customer.email", "customer.first_name", "customer.last_name" ]
9,245
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
What percentage of the movies are PG-13?
SELECT CAST(SUM(IIF(rating = 'PG-13', 1, 0)) AS REAL) * 100 / COUNT(film_id) FROM film
PG-13 is a rating; calculation = DIVIDE(SUM(rating = PG-13), SUM(rating)) * 100
[ "film.film_id", "film.rating" ]
9,246
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
Please list the top ten movies with the most price per day in descending order of price per day.
SELECT title FROM film ORDER BY rental_rate / rental_duration DESC LIMIT 10
movies with the most price per day refers to MAX(rental_rate)
[ "film.rental_duration", "film.rental_rate", "film.title" ]
9,247
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
Calculate the average rent amount paid by the customer with customer id 15.
SELECT AVG(amount) FROM payment WHERE customer_id = 15
average rent amount refers to AVG(amount)
[ "payment.amount", "payment.customer_id" ]
9,248
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
How many customers rented for an above-average period?
SELECT COUNT(customer_id) FROM rental WHERE return_date - rental_date > ( SELECT AVG(return_date - rental_date) FROM rental )
rented period refers to SUBTRACT(return_date, rental_date); calculation = rented period > (AVG(rented period))
[ "rental.customer_id", "rental.rental_date", "rental.return_date" ]
9,249
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
Among the movies, what percentage are horror?
SELECT CAST(SUM(IIF(T2.name = 'horror', 1, 0)) AS REAL) * 100 / COUNT(T2.category_id) FROM film_category AS T1 INNER JOIN category AS T2 ON T1.category_id = T2.category_id
horror is a name of film category; calculation = DIVIDE(COUNT('horror'), COUNT(category_id)) * 100
[ "category.category_id", "category.name", "film_category.category_id" ]
9,250
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
Give the full name of the actor who acted in the most number of movies?
SELECT T.first_name, T.last_name FROM ( SELECT T2.first_name, T2.last_name, COUNT(T1.film_id) AS num FROM film_actor AS T1 INNER JOIN actor AS T2 ON T1.actor_id = T2.actor_id GROUP BY T2.first_name, T2.last_name ) AS T ORDER BY T.num DESC LIMIT 1
full name refers to first_name, last_name; acted in the most number of movies refers to MAX(COUNT(film_id))
[ "T.first_name", "T.last_name", "T.num", "actor.actor_id", "actor.first_name", "actor.last_name", "film_actor.actor_id", "film_actor.film_id" ]
9,251
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
Give the full name of the actor who acted the most in drama movies?
SELECT T.first_name, T.last_name FROM ( SELECT T1.first_name, T1.last_name, COUNT(T2.film_id) AS num FROM actor AS T1 INNER JOIN film_actor AS T2 ON T1.actor_id = T2.actor_id INNER JOIN film_category AS T3 ON T2.film_id = T3.film_id WHERE T3.category_id = 7 GROUP BY T1.first_name, T1.last_name ) AS T ORDER BY T.num DES...
full name refers to first_name, last_name; drama is a category of a film; acted the most in a movies refers to MAX(COUNT(film_id))
[ "T.first_name", "T.last_name", "T.num", "actor.actor_id", "actor.first_name", "actor.last_name", "film_actor.actor_id", "film_actor.film_id", "film_category.category_id", "film_category.film_id" ]
9,252
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
What is the difference in the average number of films rented each day in Australia and Canada?
SELECT AVG(IIF(T4.country = 'Australia', 1, 0)) - AVG(IIF(T4.country = 'Canada', 1, 0)) AS diff FROM customer AS T1 INNER JOIN address AS T2 ON T1.address_id = T2.address_id INNER JOIN city AS T3 ON T2.city_id = T3.city_id INNER JOIN country AS T4 ON T3.country_id = T4.country_id
'Australia' AND 'Canada' are country; average number of films refers to AVG('Australia') AND AVG('Canada'); calculation = SUBTRACT(AVG('Australia'), AVG('Canada'))
[ "address.address_id", "address.city_id", "city.city_id", "city.country_id", "country.country", "country.country_id", "customer.address_id" ]
9,253
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
Of the movies in which Reese Kilmer acted, what percentage are action movies?
SELECT CAST(SUM(IIF(T4.name = 'Action', 1, 0)) AS REAL) * 100 / COUNT(T1.actor_id) FROM actor AS T1 INNER JOIN film_actor AS T2 ON T1.actor_id = T2.actor_id INNER JOIN film_category AS T3 ON T2.film_id = T3.film_id INNER JOIN category AS T4 ON T3.category_id = T4.category_id WHERE T1.first_name = 'Reese' AND T1.last_na...
'Reese Kilmer' is a full name of an actor; 'action' is the name of the category; calculation = DIVIDE(COUNT('action'), COUNT(category_id)) * 100
[ "actor.actor_id", "actor.first_name", "actor.last_name", "category.category_id", "category.name", "film_actor.actor_id", "film_actor.film_id", "film_category.category_id", "film_category.film_id" ]
9,254
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
Give the total amount of rent for the movie Clockwork Paradice.
SELECT SUM(T1.amount) FROM payment AS T1 INNER JOIN rental AS T2 ON T1.rental_id = T2.rental_id INNER JOIN inventory AS T3 ON T2.inventory_id = T3.inventory_id INNER JOIN film AS T4 ON T3.film_id = T4.film_id WHERE T4.title = 'CLOCKWORK PARADICE'
'Clockwork Paradice' is a title of a film
[ "film.film_id", "film.title", "inventory.film_id", "inventory.inventory_id", "payment.amount", "payment.rental_id", "rental.inventory_id", "rental.rental_id" ]
9,255
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
Find and list the full name of customers who rented more than five types of movies.
SELECT T.first_name, T.last_name FROM ( SELECT T1.first_name, T1.last_name, COUNT(T1.customer_id) AS num FROM customer AS T1 INNER JOIN rental AS T2 ON T1.customer_id = T2.customer_id INNER JOIN inventory AS T3 ON T2.inventory_id = T3.inventory_id INNER JOIN film AS T4 ON T3.film_id = T4.film_id INNER JOIN film_categor...
full name refers to first_name, last_name; types of movies means category of movies; rented more than five types of movies refers to COUNT(film_category) > 5
[ "T.first_name", "T.last_name", "T.num", "customer.customer_id", "customer.first_name", "customer.last_name", "film.film_id", "film_category.film_id", "inventory.film_id", "inventory.inventory_id", "rental.customer_id", "rental.inventory_id" ]
9,256
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
What is the average number of actors acted in comedy movies?
SELECT AVG(T1.actor_id) FROM film_actor AS T1 INNER JOIN film_category AS T2 ON T1.film_id = T2.film_id INNER JOIN category AS T3 ON T2.category_id = T3.category_id INNER JOIN actor AS T4 ON T4.actor_id = T1.actor_id WHERE T3.name = 'comedy'
comedy is the name of a category; average number of actors refers to AVG(actor_id)
[ "actor.actor_id", "category.category_id", "category.name", "film_actor.actor_id", "film_actor.film_id", "film_category.category_id", "film_category.film_id" ]
9,257
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
In children's movies, which was rented the most?
SELECT T.title FROM ( SELECT T4.title, COUNT(T4.title) AS num FROM customer AS T1 INNER JOIN rental AS T2 ON T1.customer_id = T2.customer_id INNER JOIN inventory AS T3 ON T2.inventory_id = T3.inventory_id INNER JOIN film AS T4 ON T3.film_id = T4.film_id INNER JOIN film_category AS T5 ON T4.film_id = T5.film_id INNER JO...
children is the name of the category; rented the most refers to MAX(COUNT(title))
[ "T.num", "T.title", "category.category_id", "category.name", "customer.customer_id", "film.film_id", "film.title", "film_category.category_id", "film_category.film_id", "inventory.film_id", "inventory.inventory_id", "rental.customer_id", "rental.inventory_id" ]
9,258
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
Calculate the percentage of customers who paid more than the average rent amount in store 1.
SELECT CAST(( SELECT COUNT(T1.customer_id) FROM customer AS T1 INNER JOIN payment AS T2 ON T1.customer_id = T2.customer_id WHERE T2.amount > ( SELECT AVG(amount) FROM payment ) ) AS REAL) * 100 / ( SELECT COUNT(customer_id) FROM customer )
store 1 refers to store_id = 1; average rent amount refers to AVG(amount); calculation = DIVIDE(amount > AVG(amount), COUNT(customer_id)) * 100
[ "customer.customer_id", "payment.amount", "payment.customer_id" ]
9,259
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
Find and list the full name of customers who rented more family movies than Sci-Fi movies.
SELECT DISTINCT IIF(SUM(IIF(T5.name = 'Family', 1, 0)) - SUM(IIF(T5.name = 'Sci-Fi', 1, 0)) > 0, T1.first_name, 0) FROM customer AS T1 INNER JOIN rental AS T2 ON T1.customer_id = T2.customer_id INNER JOIN inventory AS T3 ON T2.inventory_id = T3.inventory_id INNER JOIN film_category AS T4 ON T4.film_id = T3.film_id INNE...
full name refers to first_name, last_name; 'family' AND 'Sci-Fi' are names of the category; customers who rented more family movies than Sci-Fi movies refers to count(name = 'Family') > count(name = 'Sci-Fi')
[ "category.category_id", "category.name", "customer.customer_id", "customer.first_name", "film_category.category_id", "film_category.film_id", "inventory.film_id", "inventory.inventory_id", "rental.customer_id", "rental.inventory_id" ]
9,260
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
Indicate the title of all the films rated as 'Adults Only'.
SELECT title FROM film WHERE rating = 'NC-17'
'Adults Only' refers to rating = 'NC-17'
[ "film.rating", "film.title" ]
9,261
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
How many actors with the surname Kilmer are there?
SELECT COUNT(actor_id) FROM actor WHERE last_name = 'Kilmer'
surname means last_name;
[ "actor.actor_id", "actor.last_name" ]
9,262
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
How many movies have a length longer than 100?
SELECT COUNT(film_id) FROM film WHERE length > 100
length longer than 100 refers to length > 100
[ "film.film_id", "film.length" ]
9,263
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
How many payments were made throughout the month of August 2005?
SELECT SUM(amount) FROM payment WHERE payment_date LIKE '2005-08%'
payments made refers to amount; throughout the month of August 2005 refers to payment_date like '2005-08%'
[ "payment.amount", "payment.payment_date" ]
9,264
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
To which country does the address '1386 Nakhon Sawan Boulevard' belong?
SELECT T1.country FROM country AS T1 INNER JOIN city AS T2 ON T1.country_id = T2.country_id INNER JOIN address AS T3 ON T2.city_id = T3.city_id WHERE T3.address = '1386 Nakhon Sawan Boulevard'
[ "address.address", "address.city_id", "city.city_id", "city.country_id", "country.country", "country.country_id" ]
9,265
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
What language was the most used in movies released in 2006?
SELECT T.language_id FROM ( SELECT T1.language_id, COUNT(T1.language_id) AS num FROM film AS T1 INNER JOIN language AS T2 ON T1.language_id = T2.language_id WHERE STRFTIME('%Y',T1.release_year) = '2006' GROUP BY T1.language_id ) AS T ORDER BY T.num DESC LIMIT 1
released in 2006 refers to release_year = 2006; the most used language refers to MAX(COUNT(language_id))
[ "T.language_id", "T.num", "film.language_id", "film.release_year", "language.language_id" ]
9,266
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
Indicate the title of all the films that are in the Classics category.
SELECT T2.title FROM film_category AS T1 INNER JOIN film AS T2 ON T1.film_id = T2.film_id INNER JOIN category AS T3 ON T1.category_id = T3.category_id WHERE T3.name = 'Classics'
'classics' is the name of category
[ "category.category_id", "category.name", "film.film_id", "film.title", "film_category.category_id", "film_category.film_id" ]
9,267
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
How many rentals did Ella Oliver hire in June 2016?
SELECT COUNT(T1.rental_id) FROM rental AS T1 INNER JOIN customer AS T2 ON T1.customer_id = T2.customer_id WHERE T2.first_name = 'ELLA' AND T2.last_name = 'ELLA' AND date(T1.rental_date) BETWEEN '2005-06-01' AND '2005-06-30'
'Ella Oliver' is a full name of a customer; full name refers to first_name, last_name; rental hired in June 2016 refers to rental_date BETWEEN '2005-06-01' AND '2005-06-30'
[ "customer.customer_id", "customer.first_name", "customer.last_name", "rental.customer_id", "rental.rental_date", "rental.rental_id" ]
9,268
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
How many different clients have rented materials from Jon Stephens?
SELECT COUNT(T1.customer_id) FROM rental AS T1 INNER JOIN staff AS T2 ON T1.staff_id = T2.staff_id WHERE T2.first_name = 'Jon' AND T2.last_name = 'Stephens'
'Jon Stephens' is a full name of a customer; full name refers to first_name, last_name;
[ "rental.customer_id", "rental.staff_id", "staff.first_name", "staff.last_name", "staff.staff_id" ]
9,269
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
What is the total amount paid for rentals made on July 29, 2005?
SELECT SUM(T2.amount) FROM rental AS T1 INNER JOIN payment AS T2 ON T1.rental_id = T2.rental_id WHERE date(T1.rental_date) = '2005-07-29%'
July 29, 2005 refers to rental_date like '2005-07-29'
[ "payment.amount", "payment.rental_id", "rental.rental_date", "rental.rental_id" ]
9,270
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
What is the first name of the customers whose address is in the postal code that begins with 76?
SELECT T1.first_name FROM customer AS T1 INNER JOIN address AS T2 ON T1.address_id = T2.address_id WHERE SUBSTR(T2.postal_code, 1, 2) = '76'
postal code that begins with 76 refers to postal_code like '76%'
[ "address.address_id", "address.postal_code", "customer.address_id", "customer.first_name" ]
9,271
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
On what date was the rented material for the movie BLOOD ARGONAUTS returned?
SELECT T1.rental_date FROM rental AS T1 INNER JOIN inventory AS T2 ON T1.inventory_id = T2.inventory_id INNER JOIN film AS T3 ON T2.film_id = T3.film_id WHERE T3.title = 'BLOOD ARGONAUTS'
'BLOOD ARGONAUTS' is a title of a film; date a movie was returned refers to return_date
[ "film.film_id", "film.title", "inventory.film_id", "inventory.inventory_id", "rental.inventory_id", "rental.rental_date" ]
9,272
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
What is the title of the films in which Cuba Allen acted?
SELECT T3.title FROM actor AS T1 INNER JOIN film_actor AS T2 ON T1.actor_id = T2.actor_id INNER JOIN film AS T3 ON T2.film_id = T3.film_id WHERE T1.first_name = 'Cuba' AND T1.last_name = 'Allen'
'Cuba Allen' is a full name of an actor; full name refers to first_name, last_name
[ "actor.actor_id", "actor.first_name", "actor.last_name", "film.film_id", "film.title", "film_actor.actor_id", "film_actor.film_id" ]
9,273
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
How many actors acted in movies in the Music category?
SELECT COUNT(T1.actor_id) FROM actor AS T1 INNER JOIN film_actor AS T2 ON T1.actor_id = T2.actor_id INNER JOIN film AS T3 ON T2.film_id = T3.film_id INNER JOIN film_category AS T4 ON T3.film_id = T4.film_id INNER JOIN category AS T5 ON T4.category_id = T5.category_id WHERE T5.name = 'Music'
Music' is a name of a category
[ "actor.actor_id", "category.category_id", "category.name", "film.film_id", "film_actor.actor_id", "film_actor.film_id", "film_category.category_id", "film_category.film_id" ]
9,274
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
What is the full name of the actor who has acted the most times in comedy films?
SELECT T.first_name, T.last_name FROM ( SELECT T4.first_name, T4.last_name, COUNT(T2.actor_id) AS num FROM film_category AS T1 INNER JOIN film_actor AS T2 ON T1.film_id = T2.film_id INNER JOIN category AS T3 ON T1.category_id = T3.category_id INNER JOIN actor AS T4 ON T2.actor_id = T4.actor_id WHERE T3.name = 'Comedy' ...
full name refers to first_name, last_name; 'comedy' is a name of a category;
[ "T.first_name", "T.last_name", "T.num", "actor.actor_id", "actor.first_name", "actor.last_name", "category.category_id", "category.name", "film_actor.actor_id", "film_actor.film_id", "film_category.category_id", "film_category.film_id" ]
9,275
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
How many customers did not rent material at Mike's store?
SELECT COUNT(T1.customer_id) FROM customer AS T1 INNER JOIN store AS T2 ON T1.store_id = T2.store_id INNER JOIN staff AS T3 ON T2.manager_staff_id = T3.staff_id WHERE T3.first_name != 'Mike'
not at Mike's store refers to staff.first_name ! = 'Mike'
[ "customer.customer_id", "customer.store_id", "staff.first_name", "staff.staff_id", "store.manager_staff_id", "store.store_id" ]
9,276
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
Indicate the name of the actors of the films rated as 'Parents Strongly Precautioned' with the highest replacement cost.
SELECT T1.first_name, T1.last_name FROM actor AS T1 INNER JOIN film_actor AS T2 ON T1.actor_id = T2.actor_id INNER JOIN film AS T3 ON T2.film_id = T3.film_id WHERE T3.rating = 'PG-13' ORDER BY T3.replacement_cost DESC LIMIT 1
name refers to first_name, last_name; Parents Strongly Precautioned' refers to rating = 'PG-13'; highest replacement cost refers to MAX(replacement_cost)
[ "actor.actor_id", "actor.first_name", "actor.last_name", "film.film_id", "film.rating", "film.replacement_cost", "film_actor.actor_id", "film_actor.film_id" ]
9,277
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
What is the name of the client who has the largest quantity of rented material without returning it?
SELECT T.first_name FROM ( SELECT T2.first_name, COUNT(T1.rental_date) AS num FROM rental AS T1 INNER JOIN customer AS T2 ON T1.customer_id = T2.customer_id GROUP BY T2.first_name ) AS T ORDER BY T.num DESC LIMIT 1
name refers to first_name, last_name; without returning a rented material refers to return_date is null
[ "T.first_name", "T.num", "customer.customer_id", "customer.first_name", "rental.customer_id", "rental.rental_date" ]
9,278
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
How many customers live in the city of Miyakonojo?
SELECT COUNT(T3.customer_id) FROM city AS T1 INNER JOIN address AS T2 ON T1.city_id = T2.city_id INNER JOIN customer AS T3 ON T2.address_id = T3.address_id WHERE T1.city = 'Miyakonojo'
[ "address.address_id", "address.city_id", "city.city", "city.city_id", "customer.address_id", "customer.customer_id" ]
9,279
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
How many non-active clients have not returned the rented material?
SELECT COUNT(T2.customer_id) FROM rental AS T1 INNER JOIN customer AS T2 ON T1.customer_id = T2.customer_id WHERE T2.active = 0
non-active clients refers to active = 0; not returning a rented material refers to rental_date is null
[ "customer.active", "customer.customer_id", "rental.customer_id" ]
9,280
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
What is the title of the animated films that have the shortest length?
SELECT T1.title FROM film AS T1 INNER JOIN film_category AS T2 ON T1.film_id = T2.film_id INNER JOIN category AS T3 ON T2.category_id = T3.category_id ORDER BY T1.length LIMIT 1
animated film means animation; animation is a name of a category
[ "category.category_id", "film.film_id", "film.length", "film.title", "film_category.category_id", "film_category.film_id" ]
9,281
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
In which country is the store where Hector Poinexter rents equipment located?
SELECT T5.country FROM customer AS T1 INNER JOIN store AS T2 ON T1.store_id = T2.store_id INNER JOIN address AS T3 ON T2.address_id = T3.address_id INNER JOIN city AS T4 ON T3.city_id = T4.city_id INNER JOIN country AS T5 ON T4.country_id = T5.country_id WHERE T1.first_name = 'HECTOR' AND T1.last_name = 'POINDEXTER'
'Hector Poinexter' is a full name of a customer; full name refers to first_name, last_name;
[ "address.address_id", "address.city_id", "city.city_id", "city.country_id", "country.country", "country.country_id", "customer.first_name", "customer.last_name", "customer.store_id", "store.address_id", "store.store_id" ]
9,282
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
What is the average rental payment in Horror movies?
SELECT AVG(T5.amount) FROM category AS T1 INNER JOIN film_category AS T2 ON T1.category_id = T2.category_id INNER JOIN inventory AS T3 ON T2.film_id = T3.film_id INNER JOIN rental AS T4 ON T3.inventory_id = T4.inventory_id INNER JOIN payment AS T5 ON T4.rental_id = T5.rental_id WHERE T1.name = 'Horror'
'Horror' is a name of a category; average rental payment refers to AVG(amount)
[ "category.category_id", "category.name", "film_category.category_id", "film_category.film_id", "inventory.film_id", "inventory.inventory_id", "payment.amount", "payment.rental_id", "rental.inventory_id", "rental.rental_id" ]
9,283
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
What is the average amount of rent that Christy Vargas paid?
SELECT AVG(T2.amount) FROM customer AS T1 INNER JOIN payment AS T2 ON T1.customer_id = T2.customer_id WHERE T1.first_name = 'CHRISTY' AND T1.Last_name = 'VARGAS'
'Christy Vargas' is a full name of a customer; full name refers to first_name, last_name; average amount of rent refers to AVG(amount)
[ "customer.Last_name", "customer.customer_id", "customer.first_name", "payment.amount", "payment.customer_id" ]
9,284
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
What percentage of films with a length of less than 100 belong to the Drama category?
SELECT CAST(SUM(IIF(T2.length < 100 AND T3.name = 'Drama', 1, 0)) AS REAL) * 100 / COUNT(T1.film_id) FROM film_category AS T1 INNER JOIN film AS T2 ON T1.film_id = T2.film_id INNER JOIN category AS T3 ON T1.category_id = T3.category_id
Drama' is a name of a category; calculation = DIVIDE(SUM(length < 100 AND name = 'Drama'), COUNT(film_id)) * 100
[ "category.category_id", "category.name", "film.film_id", "film.length", "film_category.category_id", "film_category.film_id" ]
9,285
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
What are the actors that have the same forename as Johnny? Please include in your answer the full names of these actors.
SELECT first_name, last_name FROM actor WHERE first_name = 'Johnny'
forename means first_name; full name refers to first_name, last_name
[ "actor.first_name", "actor.last_name" ]
9,286
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
What are the address numbers that are located in Gansu district?
SELECT address_id FROM address WHERE district = 'Gansu'
address numbers refers to address_id;
[ "address.address_id", "address.district" ]
9,287
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
Please list three types of film along with their IDs and the latest update.
SELECT DISTINCT name, category_id, last_update FROM category LIMIT 3
types of film refers to the name of a category; IDs refers to category_id; latest update refers to last_update.
[ "category.category_id", "category.last_update", "category.name" ]
9,288
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
Please list the full names of any three inactive customers.
SELECT first_name, last_name FROM customer WHERE active = 0 LIMIT 3
full name refers to first_name, last_name; inactive customers refers to active = 0
[ "customer.active", "customer.first_name", "customer.last_name" ]
9,289
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
What is the rental price per day for Airplane Sierra?
SELECT rental_rate / rental_duration AS result FROM film WHERE title = 'AIRPLANE SIERRA'
rental price per day refers to DIVIDE(rental_price, rental_duration); 'Airplane Sierra' is a title of a film
[ "film.rental_duration", "film.rental_rate", "film.title" ]
9,290
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
Where is store number 2 located?
SELECT T1.address, T1.address2, T1.district FROM address AS T1 INNER JOIN store AS T2 ON T1.address_id = T2.address_id WHERE T2.store_id = 2
store number 2 refers to store_id = 2; where is a store located refers to address, address2, district
[ "address.address", "address.address2", "address.address_id", "address.district", "store.address_id", "store.store_id" ]
9,291
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
Which city does the address 1623 Kingstown Drive belong to?
SELECT T1.city FROM city AS T1 INNER JOIN address AS T2 ON T2.city_id = T1.city_id WHERE T2.address = '1623 Kingstown Drive'
[ "address.address", "address.city_id", "city.city", "city.city_id" ]
9,292
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
Please name three cities that belong to Algeria.
SELECT T2.city FROM country AS T1 INNER JOIN city AS T2 ON T1.country_id = T2.country_id WHERE T1.country = 'Algeria'
Algeria is a country
[ "city.city", "city.country_id", "country.country", "country.country_id" ]
9,293
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
What is the category of the film Agent Truman?
SELECT T3.name FROM film AS T1 INNER JOIN film_category AS T2 ON T1.film_id = T2.film_id INNER JOIN category AS T3 ON T2.category_id = T3.category_id WHERE T1.title = 'AGENT TRUMAN'
'Agent Truman' is a title of a film; category refers to name
[ "category.category_id", "category.name", "film.film_id", "film.title", "film_category.category_id", "film_category.film_id" ]
9,294
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
Please list the titles of any three action films.
SELECT T1.title FROM film AS T1 INNER JOIN film_category AS T2 ON T1.film_id = T2.film_id INNER JOIN category AS T3 ON T2.category_id = T3.category_id WHERE T3.name = 'Action' LIMIT 3
action is a name of category
[ "category.category_id", "category.name", "film.film_id", "film.title", "film_category.category_id", "film_category.film_id" ]
9,295
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
What is the difference between the number of children's films and action films?
SELECT SUM(IIF(T2.name = 'Children', 1, 0)) - SUM(IIF(T2.name = 'Action', 1, 0)) AS diff FROM film_category AS T1 INNER JOIN category AS T2 ON T1.category_id = T2.category_id
'children' AND 'action' are names of a category; Calculation = SUBTRACT(AVG('children'), AVG('action'))
[ "category.category_id", "category.name", "film_category.category_id" ]
9,296
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
Which district does Maria Miller live in?
SELECT T2.district FROM customer AS T1 INNER JOIN address AS T2 ON T1.address_id = T2.address_id WHERE T1.first_name = 'Maria' AND T1.last_name = 'Miller'
'Maria Miller' is a name of a customer; full name refers to first_name, last_name
[ "address.address_id", "address.district", "customer.address_id", "customer.first_name", "customer.last_name" ]
9,297
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
Who is the customer that is active and lives at 1795 Santiago de Compostela Way, Texas?
SELECT T1.first_name, T1.last_name FROM customer AS T1 INNER JOIN address AS T2 ON T1.address_id = T2.address_id WHERE T2.address = '1795 Santiago de Compostela Way' AND T1.active = 1
active refers to active = 1; '1795 Santiago de Compostela Way' is an address; Texas is a district; who refers to first_name, last_name
[ "address.address", "address.address_id", "customer.active", "customer.address_id", "customer.first_name", "customer.last_name" ]
9,298
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
How many English films have a duration of over 50 minutes and the cost of replacement are under 10.99?
SELECT COUNT(T1.film_id) FROM film AS T1 INNER JOIN language AS T2 ON T1.language_id = T2.language_id WHERE T2.name = 'English' AND T1.length > 50 AND T1.replacement_cost < 10.99
English is a name of a language; duration of over 50 minutes refers to length > 50; cost of replacement are under 10.99 refers to replacement_cost < 10.99
[ "film.film_id", "film.language_id", "film.length", "film.replacement_cost", "language.language_id", "language.name" ]
9,299
movie_3
CREATE TABLE film_text ( film_id INTEGER not null primary key, title TEXT not null, description TEXT null ); CREATE TABLE "actor" ( actor_id INTEGER primary key autoincrement, first_name TEXT not null, last_name TEXT ...
Who are the actors that act in the ACADEMY DINOSAUR film?
SELECT T1.first_name, T1.last_name FROM actor AS T1 INNER JOIN film_actor AS T2 ON T1.actor_id = T2.actor_id INNER JOIN film AS T3 ON T2.film_id = T3.film_id WHERE T3.title = 'ACADEMY DINOSAUR'
Who are the actors refers to full name; full name refers to first_name, last_name; 'ACADEMY DINOSAUR' is a title of a film
[ "actor.actor_id", "actor.first_name", "actor.last_name", "film.film_id", "film.title", "film_actor.actor_id", "film_actor.film_id" ]