1sf/bird-sql-train-with-schema huggingface dataset:
Database: movies_4
Tables: country, department, gender, genre, keyword, language, language_role, movie, movie_genres, movie_languages, person, movie_crew, production_company, production_country, movie_cast, movie_keywords, movie_company
Columns (table index, column name): -1, *, 0, country_id, 0, country_iso_code, 0, country_name, 1, department_id, 1, department_name, 2, gender_id, 2, gender, 3, genre_id, 3, genre_name, 4, keyword_id, 4, keyword_name, 5, language_id, 5, language_code, 5, language_name, 6, role_id, 6, language_role, 7, movie_id, 7, title, 7, budget, 7, homepage, 7, overview, 7, popularity, 7, release_date, 7, revenue, 7, runtime, 7, movie_status, 7, tagline, 7, vote_average, 7, vote_count, 8, movie_id, 8, genre_id, 9, movie_id, 9, language_id, 9, language_role_id, 10, person_id, 10, person_name, 11, movie_id, 11, person_id, 11, department_id, 11, job, 12, company_id, 12, company_name, 13, movie_id, 13, country_id, 14, movie_id, 14, person_id, 14, character_name, 14, gender_id, 14, cast_order, 15, movie_id, 15, keyword_id, 16, movie_id, 16, company_id
Question: How many movies were directed by Michael Bay?
Evidence: directed by refers to job = 'Director'
SQL: SELECT COUNT(T2.movie_id) FROM person AS T1 INNER JOIN movie_crew AS T2 ON T1.person_id = T2.person_id WHERE T1.person_name = 'Michael Bay' AND T2.job = 'Director'
Database: movies_4
Tables: country, department, gender, genre, keyword, language, language_role, movie, movie_genres, movie_languages, person, movie_crew, production_company, production_country, movie_cast, movie_keywords, movie_company
Columns (table index, column name): -1, *, 0, country_id, 0, country_iso_code, 0, country_name, 1, department_id, 1, department_name, 2, gender_id, 2, gender, 3, genre_id, 3, genre_name, 4, keyword_id, 4, keyword_name, 5, language_id, 5, language_code, 5, language_name, 6, role_id, 6, language_role, 7, movie_id, 7, title, 7, budget, 7, homepage, 7, overview, 7, popularity, 7, release_date, 7, revenue, 7, runtime, 7, movie_status, 7, tagline, 7, vote_average, 7, vote_count, 8, movie_id, 8, genre_id, 9, movie_id, 9, language_id, 9, language_role_id, 10, person_id, 10, person_name, 11, movie_id, 11, person_id, 11, department_id, 11, job, 12, company_id, 12, company_name, 13, movie_id, 13, country_id, 14, movie_id, 14, person_id, 14, character_name, 14, gender_id, 14, cast_order, 15, movie_id, 15, keyword_id, 16, movie_id, 16, company_id
Question: Show the total number of keywords of the movie "I Hope They Serve Beer in Hell".
Evidence: "I Hope They Serve Beer in Hell" refers to title = 'I Hope They Serve Beer in Hell';
SQL: SELECT COUNT(T2.keyword_id) FROM movie AS T1 INNER JOIN movie_keywords AS T2 ON T1.movie_id = T2.movie_id WHERE T1.title = 'I Hope They Serve Beer in Hell'
Database: movies_4
Tables: country, department, gender, genre, keyword, language, language_role, movie, movie_genres, movie_languages, person, movie_crew, production_company, production_country, movie_cast, movie_keywords, movie_company
Columns (table index, column name): -1, *, 0, country_id, 0, country_iso_code, 0, country_name, 1, department_id, 1, department_name, 2, gender_id, 2, gender, 3, genre_id, 3, genre_name, 4, keyword_id, 4, keyword_name, 5, language_id, 5, language_code, 5, language_name, 6, role_id, 6, language_role, 7, movie_id, 7, title, 7, budget, 7, homepage, 7, overview, 7, popularity, 7, release_date, 7, revenue, 7, runtime, 7, movie_status, 7, tagline, 7, vote_average, 7, vote_count, 8, movie_id, 8, genre_id, 9, movie_id, 9, language_id, 9, language_role_id, 10, person_id, 10, person_name, 11, movie_id, 11, person_id, 11, department_id, 11, job, 12, company_id, 12, company_name, 13, movie_id, 13, country_id, 14, movie_id, 14, person_id, 14, character_name, 14, gender_id, 14, cast_order, 15, movie_id, 15, keyword_id, 16, movie_id, 16, company_id
Question: For the movie "Land of the Dead", who is its director?
Evidence: "Land of the Dead" refers to title = 'Land of the Dead'; director refers to person_name where job = 'Director'
SQL: SELECT T3.person_name FROM movie AS T1 INNER JOIN movie_crew AS T2 ON T1.movie_id = T2.movie_id INNER JOIN person AS T3 ON T2.person_id = T3.person_id WHERE T1.title = 'Land of the Dead' AND T2.job = 'Director'
Database: movies_4
Tables: country, department, gender, genre, keyword, language, language_role, movie, movie_genres, movie_languages, person, movie_crew, production_company, production_country, movie_cast, movie_keywords, movie_company
Columns (table index, column name): -1, *, 0, country_id, 0, country_iso_code, 0, country_name, 1, department_id, 1, department_name, 2, gender_id, 2, gender, 3, genre_id, 3, genre_name, 4, keyword_id, 4, keyword_name, 5, language_id, 5, language_code, 5, language_name, 6, role_id, 6, language_role, 7, movie_id, 7, title, 7, budget, 7, homepage, 7, overview, 7, popularity, 7, release_date, 7, revenue, 7, runtime, 7, movie_status, 7, tagline, 7, vote_average, 7, vote_count, 8, movie_id, 8, genre_id, 9, movie_id, 9, language_id, 9, language_role_id, 10, person_id, 10, person_name, 11, movie_id, 11, person_id, 11, department_id, 11, job, 12, company_id, 12, company_name, 13, movie_id, 13, country_id, 14, movie_id, 14, person_id, 14, character_name, 14, gender_id, 14, cast_order, 15, movie_id, 15, keyword_id, 16, movie_id, 16, company_id
Question: Tell the number of movies made by Paramount Animation.
Evidence: Paramount Animation refers to company_name = 'Paramount Animation'
SQL: SELECT COUNT(T2.movie_id) FROM production_company AS T1 INNER JOIN movie_company AS T2 ON T1.company_id = T2.company_id WHERE T1.company_name = 'Paramount Animation'
Database: movies_4
Tables: country, department, gender, genre, keyword, language, language_role, movie, movie_genres, movie_languages, person, movie_crew, production_company, production_country, movie_cast, movie_keywords, movie_company
Columns (table index, column name): -1, *, 0, country_id, 0, country_iso_code, 0, country_name, 1, department_id, 1, department_name, 2, gender_id, 2, gender, 3, genre_id, 3, genre_name, 4, keyword_id, 4, keyword_name, 5, language_id, 5, language_code, 5, language_name, 6, role_id, 6, language_role, 7, movie_id, 7, title, 7, budget, 7, homepage, 7, overview, 7, popularity, 7, release_date, 7, revenue, 7, runtime, 7, movie_status, 7, tagline, 7, vote_average, 7, vote_count, 8, movie_id, 8, genre_id, 9, movie_id, 9, language_id, 9, language_role_id, 10, person_id, 10, person_name, 11, movie_id, 11, person_id, 11, department_id, 11, job, 12, company_id, 12, company_name, 13, movie_id, 13, country_id, 14, movie_id, 14, person_id, 14, character_name, 14, gender_id, 14, cast_order, 15, movie_id, 15, keyword_id, 16, movie_id, 16, company_id
Question: How many female characters are there in the movie "Spider-Man 3"?
Evidence: female characters refer to gender = 'Female'; "Spider-Man 3" refers to title = 'Spider-Man 3'
SQL: SELECT COUNT(*) FROM movie AS T1 INNER JOIN movie_cast AS T2 ON T1.movie_id = T2.movie_id INNER JOIN gender AS T3 ON T2.gender_id = T3.gender_id WHERE T1.title = 'Spider-Man 3' AND T3.gender = 'Female'
Database: movies_4
Tables: country, department, gender, genre, keyword, language, language_role, movie, movie_genres, movie_languages, person, movie_crew, production_company, production_country, movie_cast, movie_keywords, movie_company
Columns (table index, column name): -1, *, 0, country_id, 0, country_iso_code, 0, country_name, 1, department_id, 1, department_name, 2, gender_id, 2, gender, 3, genre_id, 3, genre_name, 4, keyword_id, 4, keyword_name, 5, language_id, 5, language_code, 5, language_name, 6, role_id, 6, language_role, 7, movie_id, 7, title, 7, budget, 7, homepage, 7, overview, 7, popularity, 7, release_date, 7, revenue, 7, runtime, 7, movie_status, 7, tagline, 7, vote_average, 7, vote_count, 8, movie_id, 8, genre_id, 9, movie_id, 9, language_id, 9, language_role_id, 10, person_id, 10, person_name, 11, movie_id, 11, person_id, 11, department_id, 11, job, 12, company_id, 12, company_name, 13, movie_id, 13, country_id, 14, movie_id, 14, person_id, 14, character_name, 14, gender_id, 14, cast_order, 15, movie_id, 15, keyword_id, 16, movie_id, 16, company_id
Question: Provide the most used keyword in the movies.
Evidence: most used keyword refers to keyword_name where max(count(keyword_name))
SQL: SELECT T1.keyword_name FROM keyword AS T1 INNER JOIN movie_keywords AS T2 ON T1.keyword_id = T2.keyword_id GROUP BY T1.keyword_name ORDER BY COUNT(T1.keyword_name) DESC LIMIT 1
Database: movies_4
Tables: country, department, gender, genre, keyword, language, language_role, movie, movie_genres, movie_languages, person, movie_crew, production_company, production_country, movie_cast, movie_keywords, movie_company
Columns (table index, column name): -1, *, 0, country_id, 0, country_iso_code, 0, country_name, 1, department_id, 1, department_name, 2, gender_id, 2, gender, 3, genre_id, 3, genre_name, 4, keyword_id, 4, keyword_name, 5, language_id, 5, language_code, 5, language_name, 6, role_id, 6, language_role, 7, movie_id, 7, title, 7, budget, 7, homepage, 7, overview, 7, popularity, 7, release_date, 7, revenue, 7, runtime, 7, movie_status, 7, tagline, 7, vote_average, 7, vote_count, 8, movie_id, 8, genre_id, 9, movie_id, 9, language_id, 9, language_role_id, 10, person_id, 10, person_name, 11, movie_id, 11, person_id, 11, department_id, 11, job, 12, company_id, 12, company_name, 13, movie_id, 13, country_id, 14, movie_id, 14, person_id, 14, character_name, 14, gender_id, 14, cast_order, 15, movie_id, 15, keyword_id, 16, movie_id, 16, company_id
Question: How many producers does the movie "The Amityville Horror" have?
Evidence: producers refers to job = 'Producer'; "The Amityville Horror" refers to title = 'The Amityville Horror'
SQL: SELECT COUNT(T2.person_id) FROM movie AS T1 INNER JOIN movie_crew AS T2 ON T1.movie_id = T2.movie_id WHERE T1.title = 'The Amityville Horror' AND T2.job = 'Producer'
Database: movies_4
Tables: country, department, gender, genre, keyword, language, language_role, movie, movie_genres, movie_languages, person, movie_crew, production_company, production_country, movie_cast, movie_keywords, movie_company
Columns (table index, column name): -1, *, 0, country_id, 0, country_iso_code, 0, country_name, 1, department_id, 1, department_name, 2, gender_id, 2, gender, 3, genre_id, 3, genre_name, 4, keyword_id, 4, keyword_name, 5, language_id, 5, language_code, 5, language_name, 6, role_id, 6, language_role, 7, movie_id, 7, title, 7, budget, 7, homepage, 7, overview, 7, popularity, 7, release_date, 7, revenue, 7, runtime, 7, movie_status, 7, tagline, 7, vote_average, 7, vote_count, 8, movie_id, 8, genre_id, 9, movie_id, 9, language_id, 9, language_role_id, 10, person_id, 10, person_name, 11, movie_id, 11, person_id, 11, department_id, 11, job, 12, company_id, 12, company_name, 13, movie_id, 13, country_id, 14, movie_id, 14, person_id, 14, character_name, 14, gender_id, 14, cast_order, 15, movie_id, 15, keyword_id, 16, movie_id, 16, company_id
Question: What is the production company of the movie "Crazy Heart"?
Evidence: movie "Crazy Heart" refers to title = 'Crazy Heart'; production company refers to company_name
SQL: SELECT T1.company_name FROM production_company AS T1 INNER JOIN movie_company AS T2 ON T1.company_id = T2.company_id INNER JOIN movie AS T3 ON T2.movie_id = T3.movie_id WHERE T3.title = 'Crazy Heart'
Database: movies_4
Tables: country, department, gender, genre, keyword, language, language_role, movie, movie_genres, movie_languages, person, movie_crew, production_company, production_country, movie_cast, movie_keywords, movie_company
Columns (table index, column name): -1, *, 0, country_id, 0, country_iso_code, 0, country_name, 1, department_id, 1, department_name, 2, gender_id, 2, gender, 3, genre_id, 3, genre_name, 4, keyword_id, 4, keyword_name, 5, language_id, 5, language_code, 5, language_name, 6, role_id, 6, language_role, 7, movie_id, 7, title, 7, budget, 7, homepage, 7, overview, 7, popularity, 7, release_date, 7, revenue, 7, runtime, 7, movie_status, 7, tagline, 7, vote_average, 7, vote_count, 8, movie_id, 8, genre_id, 9, movie_id, 9, language_id, 9, language_role_id, 10, person_id, 10, person_name, 11, movie_id, 11, person_id, 11, department_id, 11, job, 12, company_id, 12, company_name, 13, movie_id, 13, country_id, 14, movie_id, 14, person_id, 14, character_name, 14, gender_id, 14, cast_order, 15, movie_id, 15, keyword_id, 16, movie_id, 16, company_id
Question: Give the number of movies with "saving the world" as the keyword.
Evidence: "saving the world" as the keyword refers to keyword_name = 'saving the world'
SQL: SELECT COUNT(T2.movie_id) FROM keyword AS T1 INNER JOIN movie_keywords AS T2 ON T1.keyword_id = T2.keyword_id WHERE keyword_name = 'saving the world'
Database: movies_4
Tables: country, department, gender, genre, keyword, language, language_role, movie, movie_genres, movie_languages, person, movie_crew, production_company, production_country, movie_cast, movie_keywords, movie_company
Columns (table index, column name): -1, *, 0, country_id, 0, country_iso_code, 0, country_name, 1, department_id, 1, department_name, 2, gender_id, 2, gender, 3, genre_id, 3, genre_name, 4, keyword_id, 4, keyword_name, 5, language_id, 5, language_code, 5, language_name, 6, role_id, 6, language_role, 7, movie_id, 7, title, 7, budget, 7, homepage, 7, overview, 7, popularity, 7, release_date, 7, revenue, 7, runtime, 7, movie_status, 7, tagline, 7, vote_average, 7, vote_count, 8, movie_id, 8, genre_id, 9, movie_id, 9, language_id, 9, language_role_id, 10, person_id, 10, person_name, 11, movie_id, 11, person_id, 11, department_id, 11, job, 12, company_id, 12, company_name, 13, movie_id, 13, country_id, 14, movie_id, 14, person_id, 14, character_name, 14, gender_id, 14, cast_order, 15, movie_id, 15, keyword_id, 16, movie_id, 16, company_id
Question: For all the movies which were produced by Cruel and Unusual Films, which one has the most popularity?
Evidence: produced by Cruel and Unusual Films refers to company_name = 'Cruel and Unusual Films'; most popularity refers to max(popularity)
SQL: SELECT T3.title FROM production_company AS T1 INNER JOIN movie_company AS T2 ON T1.company_id = T2.company_id INNER JOIN movie AS T3 ON T2.movie_id = T3.movie_id WHERE T1.company_name = 'Cruel and Unusual Films' ORDER BY T3.popularity DESC LIMIT 1
Database: movies_4
Tables: country, department, gender, genre, keyword, language, language_role, movie, movie_genres, movie_languages, person, movie_crew, production_company, production_country, movie_cast, movie_keywords, movie_company
Columns (table index, column name): -1, *, 0, country_id, 0, country_iso_code, 0, country_name, 1, department_id, 1, department_name, 2, gender_id, 2, gender, 3, genre_id, 3, genre_name, 4, keyword_id, 4, keyword_name, 5, language_id, 5, language_code, 5, language_name, 6, role_id, 6, language_role, 7, movie_id, 7, title, 7, budget, 7, homepage, 7, overview, 7, popularity, 7, release_date, 7, revenue, 7, runtime, 7, movie_status, 7, tagline, 7, vote_average, 7, vote_count, 8, movie_id, 8, genre_id, 9, movie_id, 9, language_id, 9, language_role_id, 10, person_id, 10, person_name, 11, movie_id, 11, person_id, 11, department_id, 11, job, 12, company_id, 12, company_name, 13, movie_id, 13, country_id, 14, movie_id, 14, person_id, 14, character_name, 14, gender_id, 14, cast_order, 15, movie_id, 15, keyword_id, 16, movie_id, 16, company_id
Question: For the movie "Reign of Fire", which department was Marcia Ross in?
Evidence: movie "Reign of Fire" refers to title = 'Reign of Fire'; which department refers to department_name
SQL: SELECT T4.department_name FROM movie AS T1 INNER JOIN movie_crew AS T2 ON T1.movie_id = T2.movie_id INNER JOIN person AS T3 ON T2.person_id = T3.person_id INNER JOIN department AS T4 ON T2.department_id = T4.department_id WHERE T3.person_name = 'Marcia Ross' AND T1.title = 'Reign of Fire'
Database: movies_4
Tables: country, department, gender, genre, keyword, language, language_role, movie, movie_genres, movie_languages, person, movie_crew, production_company, production_country, movie_cast, movie_keywords, movie_company
Columns (table index, column name): -1, *, 0, country_id, 0, country_iso_code, 0, country_name, 1, department_id, 1, department_name, 2, gender_id, 2, gender, 3, genre_id, 3, genre_name, 4, keyword_id, 4, keyword_name, 5, language_id, 5, language_code, 5, language_name, 6, role_id, 6, language_role, 7, movie_id, 7, title, 7, budget, 7, homepage, 7, overview, 7, popularity, 7, release_date, 7, revenue, 7, runtime, 7, movie_status, 7, tagline, 7, vote_average, 7, vote_count, 8, movie_id, 8, genre_id, 9, movie_id, 9, language_id, 9, language_role_id, 10, person_id, 10, person_name, 11, movie_id, 11, person_id, 11, department_id, 11, job, 12, company_id, 12, company_name, 13, movie_id, 13, country_id, 14, movie_id, 14, person_id, 14, character_name, 14, gender_id, 14, cast_order, 15, movie_id, 15, keyword_id, 16, movie_id, 16, company_id
Question: Calculate the average budget of the movies directed by Jaume Collet-Serra.
Evidence: directed by refers to job = 'Director'; average budget = AVG(budget)
SQL: SELECT CAST(SUM(T1.budget) AS REAL) / COUNT(T1.movie_id) FROM movie AS T1 INNER JOIN movie_crew AS T2 ON T1.movie_id = T2.movie_id INNER JOIN person AS T3 ON T2.person_id = T3.person_id WHERE T3.person_name = 'Jaume Collet-Serra' AND T2.job = 'Director'
Database: movies_4
Tables: country, department, gender, genre, keyword, language, language_role, movie, movie_genres, movie_languages, person, movie_crew, production_company, production_country, movie_cast, movie_keywords, movie_company
Columns (table index, column name): -1, *, 0, country_id, 0, country_iso_code, 0, country_name, 1, department_id, 1, department_name, 2, gender_id, 2, gender, 3, genre_id, 3, genre_name, 4, keyword_id, 4, keyword_name, 5, language_id, 5, language_code, 5, language_name, 6, role_id, 6, language_role, 7, movie_id, 7, title, 7, budget, 7, homepage, 7, overview, 7, popularity, 7, release_date, 7, revenue, 7, runtime, 7, movie_status, 7, tagline, 7, vote_average, 7, vote_count, 8, movie_id, 8, genre_id, 9, movie_id, 9, language_id, 9, language_role_id, 10, person_id, 10, person_name, 11, movie_id, 11, person_id, 11, department_id, 11, job, 12, company_id, 12, company_name, 13, movie_id, 13, country_id, 14, movie_id, 14, person_id, 14, character_name, 14, gender_id, 14, cast_order, 15, movie_id, 15, keyword_id, 16, movie_id, 16, company_id
Question: What is the percentage of male characters in the movie "Bride Wars"?
Evidence: male refers to gender = 'Male'; "Bride Wars" refers to title = 'Bride Wars'; percentage = divide(sum(gender = 'Male'), count(gender)) * 100 as percentage
SQL: SELECT CAST(COUNT(CASE WHEN T3.gender = 'Male' THEN 1 ELSE NULL END) AS REAL) * 100 / COUNT(T3.gender) FROM movie AS T1 INNER JOIN movie_cast AS T2 ON T1.movie_id = T2.movie_id INNER JOIN gender AS T3 ON T2.gender_id = T3.gender_id WHERE T1.title = 'Bride Wars'
Database: movies_4
Tables: country, department, gender, genre, keyword, language, language_role, movie, movie_genres, movie_languages, person, movie_crew, production_company, production_country, movie_cast, movie_keywords, movie_company
Columns (table index, column name): -1, *, 0, country_id, 0, country_iso_code, 0, country_name, 1, department_id, 1, department_name, 2, gender_id, 2, gender, 3, genre_id, 3, genre_name, 4, keyword_id, 4, keyword_name, 5, language_id, 5, language_code, 5, language_name, 6, role_id, 6, language_role, 7, movie_id, 7, title, 7, budget, 7, homepage, 7, overview, 7, popularity, 7, release_date, 7, revenue, 7, runtime, 7, movie_status, 7, tagline, 7, vote_average, 7, vote_count, 8, movie_id, 8, genre_id, 9, movie_id, 9, language_id, 9, language_role_id, 10, person_id, 10, person_name, 11, movie_id, 11, person_id, 11, department_id, 11, job, 12, company_id, 12, company_name, 13, movie_id, 13, country_id, 14, movie_id, 14, person_id, 14, character_name, 14, gender_id, 14, cast_order, 15, movie_id, 15, keyword_id, 16, movie_id, 16, company_id
Question: What is the title of the movie that was made with the most money and resources?
Evidence: made with the most money and resources refers to max(budget)
SQL: SELECT title FROM movie ORDER BY budget DESC LIMIT 1
Database: movies_4
Tables: country, department, gender, genre, keyword, language, language_role, movie, movie_genres, movie_languages, person, movie_crew, production_company, production_country, movie_cast, movie_keywords, movie_company
Columns (table index, column name): -1, *, 0, country_id, 0, country_iso_code, 0, country_name, 1, department_id, 1, department_name, 2, gender_id, 2, gender, 3, genre_id, 3, genre_name, 4, keyword_id, 4, keyword_name, 5, language_id, 5, language_code, 5, language_name, 6, role_id, 6, language_role, 7, movie_id, 7, title, 7, budget, 7, homepage, 7, overview, 7, popularity, 7, release_date, 7, revenue, 7, runtime, 7, movie_status, 7, tagline, 7, vote_average, 7, vote_count, 8, movie_id, 8, genre_id, 9, movie_id, 9, language_id, 9, language_role_id, 10, person_id, 10, person_name, 11, movie_id, 11, person_id, 11, department_id, 11, job, 12, company_id, 12, company_name, 13, movie_id, 13, country_id, 14, movie_id, 14, person_id, 14, character_name, 14, gender_id, 14, cast_order, 15, movie_id, 15, keyword_id, 16, movie_id, 16, company_id
Question: How many movies have made at least 1 Billion at the box office?
Evidence: have made at least 1 Billion at the box office refers to revenue > 1000000000
SQL: SELECT COUNT(movie_id) FROM movie WHERE revenue > 1000000000
Database: movies_4
Tables: country, department, gender, genre, keyword, language, language_role, movie, movie_genres, movie_languages, person, movie_crew, production_company, production_country, movie_cast, movie_keywords, movie_company
Columns (table index, column name): -1, *, 0, country_id, 0, country_iso_code, 0, country_name, 1, department_id, 1, department_name, 2, gender_id, 2, gender, 3, genre_id, 3, genre_name, 4, keyword_id, 4, keyword_name, 5, language_id, 5, language_code, 5, language_name, 6, role_id, 6, language_role, 7, movie_id, 7, title, 7, budget, 7, homepage, 7, overview, 7, popularity, 7, release_date, 7, revenue, 7, runtime, 7, movie_status, 7, tagline, 7, vote_average, 7, vote_count, 8, movie_id, 8, genre_id, 9, movie_id, 9, language_id, 9, language_role_id, 10, person_id, 10, person_name, 11, movie_id, 11, person_id, 11, department_id, 11, job, 12, company_id, 12, company_name, 13, movie_id, 13, country_id, 14, movie_id, 14, person_id, 14, character_name, 14, gender_id, 14, cast_order, 15, movie_id, 15, keyword_id, 16, movie_id, 16, company_id
Question: When was the first movie released?
Evidence: when the first movie refers to release_date where min(release_date)
SQL: SELECT MIN(release_date) FROM movie WHERE movie_status = 'Released'
Database: movies_4
Tables: country, department, gender, genre, keyword, language, language_role, movie, movie_genres, movie_languages, person, movie_crew, production_company, production_country, movie_cast, movie_keywords, movie_company
Columns (table index, column name): -1, *, 0, country_id, 0, country_iso_code, 0, country_name, 1, department_id, 1, department_name, 2, gender_id, 2, gender, 3, genre_id, 3, genre_name, 4, keyword_id, 4, keyword_name, 5, language_id, 5, language_code, 5, language_name, 6, role_id, 6, language_role, 7, movie_id, 7, title, 7, budget, 7, homepage, 7, overview, 7, popularity, 7, release_date, 7, revenue, 7, runtime, 7, movie_status, 7, tagline, 7, vote_average, 7, vote_count, 8, movie_id, 8, genre_id, 9, movie_id, 9, language_id, 9, language_role_id, 10, person_id, 10, person_name, 11, movie_id, 11, person_id, 11, department_id, 11, job, 12, company_id, 12, company_name, 13, movie_id, 13, country_id, 14, movie_id, 14, person_id, 14, character_name, 14, gender_id, 14, cast_order, 15, movie_id, 15, keyword_id, 16, movie_id, 16, company_id
Question: How many crew are named John Young?
SQL: SELECT COUNT(person_id) FROM person WHERE person_name = 'John Young'