1sf/bird-sql-train-with-schema huggingface dataset:
Database: law_episode
Tables: Episode, Keyword, Person, Award, Credit, Vote
Columns (table index, column name): -1, *, 0, episode_id, 0, series, 0, season, 0, episode, 0, number_in_series, 0, title, 0, summary, 0, air_date, 0, episode_image, 0, rating, 0, votes, 1, episode_id, 1, keyword, 2, person_id, 2, name, 2, birthdate, 2, birth_name, 2, birth_place, 2, birth_region, 2, birth_country, 2, height_meters, 2, nickname, 3, award_id, 3, organization, 3, year, 3, award_category, 3, award, 3, series, 3, episode_id, 3, person_id, 3, role, 3, result, 4, episode_id, 4, person_id, 4, category, 4, role, 4, credited, 5, episode_id, 5, stars, 5, votes, 5, percent
Question: How many people, who were born in Canada, won an award in 1999?
Evidence: born in Canada refers to birth_country = 'Canada'; in 1999 refers to year = 1999
SQL: SELECT COUNT(T1.person_id) FROM Person AS T1 INNER JOIN Award AS T2 ON T1.person_id = T2.person_id WHERE T2.year = 1999 AND T1.birth_country = 'Canada'
Database: law_episode
Tables: Episode, Keyword, Person, Award, Credit, Vote
Columns (table index, column name): -1, *, 0, episode_id, 0, series, 0, season, 0, episode, 0, number_in_series, 0, title, 0, summary, 0, air_date, 0, episode_image, 0, rating, 0, votes, 1, episode_id, 1, keyword, 2, person_id, 2, name, 2, birthdate, 2, birth_name, 2, birth_place, 2, birth_region, 2, birth_country, 2, height_meters, 2, nickname, 3, award_id, 3, organization, 3, year, 3, award_category, 3, award, 3, series, 3, episode_id, 3, person_id, 3, role, 3, result, 4, episode_id, 4, person_id, 4, category, 4, role, 4, credited, 5, episode_id, 5, stars, 5, votes, 5, percent
Question: How many people gave the most enjoyed episode a 10-star rating?
Evidence: the most enjoyed refers max(rating); 10-star refers to stars = 10
SQL: SELECT COUNT(T1.episode_id) FROM Episode AS T1 INNER JOIN Vote AS T2 ON T1.episode_id = T2.episode_id WHERE T2.stars = 10
Database: law_episode
Tables: Episode, Keyword, Person, Award, Credit, Vote
Columns (table index, column name): -1, *, 0, episode_id, 0, series, 0, season, 0, episode, 0, number_in_series, 0, title, 0, summary, 0, air_date, 0, episode_image, 0, rating, 0, votes, 1, episode_id, 1, keyword, 2, person_id, 2, name, 2, birthdate, 2, birth_name, 2, birth_place, 2, birth_region, 2, birth_country, 2, height_meters, 2, nickname, 3, award_id, 3, organization, 3, year, 3, award_category, 3, award, 3, series, 3, episode_id, 3, person_id, 3, role, 3, result, 4, episode_id, 4, person_id, 4, category, 4, role, 4, credited, 5, episode_id, 5, stars, 5, votes, 5, percent
Question: What are the keywords of the "Shield" episode?
Evidence: "Shield" episode refers to title = 'Shield'
SQL: SELECT T2.keyword FROM Episode AS T1 INNER JOIN Keyword AS T2 ON T1.episode_id = T2.episode_id WHERE T1.title = 'Shield'
Database: law_episode
Tables: Episode, Keyword, Person, Award, Credit, Vote
Columns (table index, column name): -1, *, 0, episode_id, 0, series, 0, season, 0, episode, 0, number_in_series, 0, title, 0, summary, 0, air_date, 0, episode_image, 0, rating, 0, votes, 1, episode_id, 1, keyword, 2, person_id, 2, name, 2, birthdate, 2, birth_name, 2, birth_place, 2, birth_region, 2, birth_country, 2, height_meters, 2, nickname, 3, award_id, 3, organization, 3, year, 3, award_category, 3, award, 3, series, 3, episode_id, 3, person_id, 3, role, 3, result, 4, episode_id, 4, person_id, 4, category, 4, role, 4, credited, 5, episode_id, 5, stars, 5, votes, 5, percent
Question: What is the percentage of people who gave the "True North" episode a 1-star rating?
Evidence: the "True North" episode refers to title = 'True North'; 1-star refers to stars = 1; percentage = divide(count(episode_id where stars = 1), count(episode_id)) * 100% where title = 'True North'
SQL: SELECT CAST(SUM(CASE WHEN T2.stars = 1 THEN 1 ELSE 0 END) AS REAL) * 100 / COUNT(T1.episode_id) FROM Episode AS T1 INNER JOIN Vote AS T2 ON T1.episode_id = T2.episode_id WHERE T1.title = 'True North' AND T1.episode_id = 'tt0629477'
Database: law_episode
Tables: Episode, Keyword, Person, Award, Credit, Vote
Columns (table index, column name): -1, *, 0, episode_id, 0, series, 0, season, 0, episode, 0, number_in_series, 0, title, 0, summary, 0, air_date, 0, episode_image, 0, rating, 0, votes, 1, episode_id, 1, keyword, 2, person_id, 2, name, 2, birthdate, 2, birth_name, 2, birth_place, 2, birth_region, 2, birth_country, 2, height_meters, 2, nickname, 3, award_id, 3, organization, 3, year, 3, award_category, 3, award, 3, series, 3, episode_id, 3, person_id, 3, role, 3, result, 4, episode_id, 4, person_id, 4, category, 4, role, 4, credited, 5, episode_id, 5, stars, 5, votes, 5, percent
Question: What is the title of the episode with the highest number of keywords?
Evidence: the highest number of keywords refers to max(count(keyword))
SQL: SELECT T1.title FROM Episode AS T1 INNER JOIN Keyword AS T2 ON T1.episode_id = T2.episode_id GROUP BY T1.episode_id ORDER BY COUNT(T2.keyword) DESC LIMIT 1
Database: law_episode
Tables: Episode, Keyword, Person, Award, Credit, Vote
Columns (table index, column name): -1, *, 0, episode_id, 0, series, 0, season, 0, episode, 0, number_in_series, 0, title, 0, summary, 0, air_date, 0, episode_image, 0, rating, 0, votes, 1, episode_id, 1, keyword, 2, person_id, 2, name, 2, birthdate, 2, birth_name, 2, birth_place, 2, birth_region, 2, birth_country, 2, height_meters, 2, nickname, 3, award_id, 3, organization, 3, year, 3, award_category, 3, award, 3, series, 3, episode_id, 3, person_id, 3, role, 3, result, 4, episode_id, 4, person_id, 4, category, 4, role, 4, credited, 5, episode_id, 5, stars, 5, votes, 5, percent
Question: Among the episodes that were aired in 1998, how many won an International Monitor Awards?
Evidence: aired in 1998 refers to air_date like '1998%'; won refers to result = 'Winner'; International Monitor Awards refers to organization = 'International Monitor Awards'
SQL: SELECT COUNT(T1.episode_id) FROM Episode AS T1 INNER JOIN Award AS T2 ON T1.episode_id = T2.episode_id WHERE strftime('%Y', T1.air_date) = '1998' AND T2.organization = 'International Monitor Awards' AND T2.result = 'Winner'
Database: law_episode
Tables: Episode, Keyword, Person, Award, Credit, Vote
Columns (table index, column name): -1, *, 0, episode_id, 0, series, 0, season, 0, episode, 0, number_in_series, 0, title, 0, summary, 0, air_date, 0, episode_image, 0, rating, 0, votes, 1, episode_id, 1, keyword, 2, person_id, 2, name, 2, birthdate, 2, birth_name, 2, birth_place, 2, birth_region, 2, birth_country, 2, height_meters, 2, nickname, 3, award_id, 3, organization, 3, year, 3, award_category, 3, award, 3, series, 3, episode_id, 3, person_id, 3, role, 3, result, 4, episode_id, 4, person_id, 4, category, 4, role, 4, credited, 5, episode_id, 5, stars, 5, votes, 5, percent
Question: How many times did the episode titled "Agony" win an award?
Evidence: titled "Agony" refers to title = 'Agony'; win an award refers to result = 'Winner'
SQL: SELECT COUNT(T2.award_id) FROM Episode AS T1 INNER JOIN Award AS T2 ON T1.episode_id = T2.episode_id WHERE T1.title = 'Agony' AND T2.result = 'Winner'
Database: law_episode
Tables: Episode, Keyword, Person, Award, Credit, Vote
Columns (table index, column name): -1, *, 0, episode_id, 0, series, 0, season, 0, episode, 0, number_in_series, 0, title, 0, summary, 0, air_date, 0, episode_image, 0, rating, 0, votes, 1, episode_id, 1, keyword, 2, person_id, 2, name, 2, birthdate, 2, birth_name, 2, birth_place, 2, birth_region, 2, birth_country, 2, height_meters, 2, nickname, 3, award_id, 3, organization, 3, year, 3, award_category, 3, award, 3, series, 3, episode_id, 3, person_id, 3, role, 3, result, 4, episode_id, 4, person_id, 4, category, 4, role, 4, credited, 5, episode_id, 5, stars, 5, votes, 5, percent
Question: How many episodes are there in the 9th season of Law and Order? Calculate the average number of casts per season of the said series.
Evidence: the 9th season refers to season = 9; Law and Order refers to series = 'Law and Order'; cast refers to category = 'Cast'; average number of casts per season = divide(count(person_id), count(episode_id))
SQL: SELECT SUM(CASE WHEN T2.season = 9 THEN 1 ELSE 0 END) AS num , CAST(SUM(CASE WHEN T2.season = 9 THEN 1 ELSE 0 END) AS REAL) / COUNT(T1.episode_id) FROM Credit AS T1 INNER JOIN Episode AS T2 ON T1.episode_id = T2.episode_id WHERE T1.category = 'Cast' AND T2.series = 'Law and Order'
Database: law_episode
Tables: Episode, Keyword, Person, Award, Credit, Vote
Columns (table index, column name): -1, *, 0, episode_id, 0, series, 0, season, 0, episode, 0, number_in_series, 0, title, 0, summary, 0, air_date, 0, episode_image, 0, rating, 0, votes, 1, episode_id, 1, keyword, 2, person_id, 2, name, 2, birthdate, 2, birth_name, 2, birth_place, 2, birth_region, 2, birth_country, 2, height_meters, 2, nickname, 3, award_id, 3, organization, 3, year, 3, award_category, 3, award, 3, series, 3, episode_id, 3, person_id, 3, role, 3, result, 4, episode_id, 4, person_id, 4, category, 4, role, 4, credited, 5, episode_id, 5, stars, 5, votes, 5, percent
Question: What are the keywords of the episode which received the 2nd-highest number of votes?
Evidence: the 2nd-highest number of votes refers to second max(votes)
SQL: SELECT T2.keyword FROM Episode AS T1 INNER JOIN Keyword AS T2 ON T1.episode_id = T2.episode_id WHERE T1.votes NOT IN ( SELECT MAX(T1.votes) FROM Episode AS T1 INNER JOIN Keyword AS T2 ON T1.episode_id = T2.episode_id ) ORDER BY T1.votes DESC LIMIT 1
Database: law_episode
Tables: Episode, Keyword, Person, Award, Credit, Vote
Columns (table index, column name): -1, *, 0, episode_id, 0, series, 0, season, 0, episode, 0, number_in_series, 0, title, 0, summary, 0, air_date, 0, episode_image, 0, rating, 0, votes, 1, episode_id, 1, keyword, 2, person_id, 2, name, 2, birthdate, 2, birth_name, 2, birth_place, 2, birth_region, 2, birth_country, 2, height_meters, 2, nickname, 3, award_id, 3, organization, 3, year, 3, award_category, 3, award, 3, series, 3, episode_id, 3, person_id, 3, role, 3, result, 4, episode_id, 4, person_id, 4, category, 4, role, 4, credited, 5, episode_id, 5, stars, 5, votes, 5, percent
Question: How many awards did the "Agony" win?
Evidence: the "Agony" refers to title = 'Agony'; win refers to result = 'Winner'
SQL: SELECT COUNT(T2.award) FROM Episode AS T1 INNER JOIN Award AS T2 ON T1.episode_id = T2.episode_id WHERE T1.title = 'Agony' AND T2.result = 'Winner'
Database: law_episode
Tables: Episode, Keyword, Person, Award, Credit, Vote
Columns (table index, column name): -1, *, 0, episode_id, 0, series, 0, season, 0, episode, 0, number_in_series, 0, title, 0, summary, 0, air_date, 0, episode_image, 0, rating, 0, votes, 1, episode_id, 1, keyword, 2, person_id, 2, name, 2, birthdate, 2, birth_name, 2, birth_place, 2, birth_region, 2, birth_country, 2, height_meters, 2, nickname, 3, award_id, 3, organization, 3, year, 3, award_category, 3, award, 3, series, 3, episode_id, 3, person_id, 3, role, 3, result, 4, episode_id, 4, person_id, 4, category, 4, role, 4, credited, 5, episode_id, 5, stars, 5, votes, 5, percent
Question: Who is the narrator of the "Flight" episode?
Evidence: who refers to name; narrator refers to role = 'Narrator'; the "Flight" episode refers to title = 'Flight'
SQL: SELECT T3.name FROM Episode AS T1 INNER JOIN Credit AS T2 ON T1.episode_id = T2.episode_id INNER JOIN Person AS T3 ON T3.person_id = T2.person_id WHERE T1.title = 'Flight' AND T2.role = 'Narrator'
Database: law_episode
Tables: Episode, Keyword, Person, Award, Credit, Vote
Columns (table index, column name): -1, *, 0, episode_id, 0, series, 0, season, 0, episode, 0, number_in_series, 0, title, 0, summary, 0, air_date, 0, episode_image, 0, rating, 0, votes, 1, episode_id, 1, keyword, 2, person_id, 2, name, 2, birthdate, 2, birth_name, 2, birth_place, 2, birth_region, 2, birth_country, 2, height_meters, 2, nickname, 3, award_id, 3, organization, 3, year, 3, award_category, 3, award, 3, series, 3, episode_id, 3, person_id, 3, role, 3, result, 4, episode_id, 4, person_id, 4, category, 4, role, 4, credited, 5, episode_id, 5, stars, 5, votes, 5, percent
Question: In which organization did Constantine Makris win the most awards?
Evidence: win refers to result = 'Winner'; the most awards refers to max(count(award_id))
SQL: SELECT T2.organization FROM Person AS T1 INNER JOIN Award AS T2 ON T1.person_id = T2.person_id WHERE T1.name = 'Constantine Makris' AND T2.result = 'Winner' GROUP BY T2.organization ORDER BY COUNT(T2.award_id) DESC LIMIT 1
Database: law_episode
Tables: Episode, Keyword, Person, Award, Credit, Vote
Columns (table index, column name): -1, *, 0, episode_id, 0, series, 0, season, 0, episode, 0, number_in_series, 0, title, 0, summary, 0, air_date, 0, episode_image, 0, rating, 0, votes, 1, episode_id, 1, keyword, 2, person_id, 2, name, 2, birthdate, 2, birth_name, 2, birth_place, 2, birth_region, 2, birth_country, 2, height_meters, 2, nickname, 3, award_id, 3, organization, 3, year, 3, award_category, 3, award, 3, series, 3, episode_id, 3, person_id, 3, role, 3, result, 4, episode_id, 4, person_id, 4, category, 4, role, 4, credited, 5, episode_id, 5, stars, 5, votes, 5, percent
Question: Who is the stunt coordinator in episode 3?
Evidence: who refers to name; stunt coordinator refers to role = 'stunt coordinator'
SQL: SELECT T3.name FROM Episode AS T1 INNER JOIN Credit AS T2 ON T1.episode_id = T2.episode_id INNER JOIN Person AS T3 ON T3.person_id = T2.person_id WHERE T1.episode = 3 AND T2.role = 'stunt coordinator'
Database: law_episode
Tables: Episode, Keyword, Person, Award, Credit, Vote
Columns (table index, column name): -1, *, 0, episode_id, 0, series, 0, season, 0, episode, 0, number_in_series, 0, title, 0, summary, 0, air_date, 0, episode_image, 0, rating, 0, votes, 1, episode_id, 1, keyword, 2, person_id, 2, name, 2, birthdate, 2, birth_name, 2, birth_place, 2, birth_region, 2, birth_country, 2, height_meters, 2, nickname, 3, award_id, 3, organization, 3, year, 3, award_category, 3, award, 3, series, 3, episode_id, 3, person_id, 3, role, 3, result, 4, episode_id, 4, person_id, 4, category, 4, role, 4, credited, 5, episode_id, 5, stars, 5, votes, 5, percent
Question: How many people were not credited at the end of the "Admissions" episode?
Evidence: not credited refers to credited = ''; the "Admissions" episode refers to title = 'Admissions'
SQL: SELECT COUNT(T2.person_id) FROM Episode AS T1 INNER JOIN Credit AS T2 ON T1.episode_id = T2.episode_id WHERE T1.title = 'Admissions' AND T2.credited = 'false'
Database: law_episode
Tables: Episode, Keyword, Person, Award, Credit, Vote
Columns (table index, column name): -1, *, 0, episode_id, 0, series, 0, season, 0, episode, 0, number_in_series, 0, title, 0, summary, 0, air_date, 0, episode_image, 0, rating, 0, votes, 1, episode_id, 1, keyword, 2, person_id, 2, name, 2, birthdate, 2, birth_name, 2, birth_place, 2, birth_region, 2, birth_country, 2, height_meters, 2, nickname, 3, award_id, 3, organization, 3, year, 3, award_category, 3, award, 3, series, 3, episode_id, 3, person_id, 3, role, 3, result, 4, episode_id, 4, person_id, 4, category, 4, role, 4, credited, 5, episode_id, 5, stars, 5, votes, 5, percent
Question: What is the title of the episode that has the highest number of crews in the Art Department?
Evidence: the highest number of crews refers to max(count(person_id)); in the Art Department refers to category = 'Art Department'
SQL: SELECT T2.title FROM Credit AS T1 INNER JOIN Episode AS T2 ON T1.episode_id = T2.episode_id WHERE T1.category = 'Art Department' GROUP BY T2.episode_id ORDER BY COUNT(T1.category) DESC LIMIT 1
Database: law_episode
Tables: Episode, Keyword, Person, Award, Credit, Vote
Columns (table index, column name): -1, *, 0, episode_id, 0, series, 0, season, 0, episode, 0, number_in_series, 0, title, 0, summary, 0, air_date, 0, episode_image, 0, rating, 0, votes, 1, episode_id, 1, keyword, 2, person_id, 2, name, 2, birthdate, 2, birth_name, 2, birth_place, 2, birth_region, 2, birth_country, 2, height_meters, 2, nickname, 3, award_id, 3, organization, 3, year, 3, award_category, 3, award, 3, series, 3, episode_id, 3, person_id, 3, role, 3, result, 4, episode_id, 4, person_id, 4, category, 4, role, 4, credited, 5, episode_id, 5, stars, 5, votes, 5, percent
Question: How many roles did Julia Roberts play in the series?
SQL: SELECT COUNT(T1.role) FROM Credit AS T1 INNER JOIN Person AS T2 ON T2.person_id = T1.person_id WHERE T2.name = 'Julia Roberts'
Database: law_episode
Tables: Episode, Keyword, Person, Award, Credit, Vote
Columns (table index, column name): -1, *, 0, episode_id, 0, series, 0, season, 0, episode, 0, number_in_series, 0, title, 0, summary, 0, air_date, 0, episode_image, 0, rating, 0, votes, 1, episode_id, 1, keyword, 2, person_id, 2, name, 2, birthdate, 2, birth_name, 2, birth_place, 2, birth_region, 2, birth_country, 2, height_meters, 2, nickname, 3, award_id, 3, organization, 3, year, 3, award_category, 3, award, 3, series, 3, episode_id, 3, person_id, 3, role, 3, result, 4, episode_id, 4, person_id, 4, category, 4, role, 4, credited, 5, episode_id, 5, stars, 5, votes, 5, percent
Question: What are the titles of the top 3 episodes that received no less than 30 votes in its 10-star rating?
Evidence: no less than 30 votes refers to votes > = 30; 10-star rating refers to stars = 10
SQL: SELECT T2.title FROM Vote AS T1 INNER JOIN Episode AS T2 ON T2.episode_id = T1.episode_id WHERE T1.votes >= 30 AND T1.stars = 10 ORDER BY T1.votes DESC LIMIT 3
Database: law_episode
Tables: Episode, Keyword, Person, Award, Credit, Vote
Columns (table index, column name): -1, *, 0, episode_id, 0, series, 0, season, 0, episode, 0, number_in_series, 0, title, 0, summary, 0, air_date, 0, episode_image, 0, rating, 0, votes, 1, episode_id, 1, keyword, 2, person_id, 2, name, 2, birthdate, 2, birth_name, 2, birth_place, 2, birth_region, 2, birth_country, 2, height_meters, 2, nickname, 3, award_id, 3, organization, 3, year, 3, award_category, 3, award, 3, series, 3, episode_id, 3, person_id, 3, role, 3, result, 4, episode_id, 4, person_id, 4, category, 4, role, 4, credited, 5, episode_id, 5, stars, 5, votes, 5, percent
Question: Who is the youngest person to ever play a "clerk" role in the series?
Evidence: who refers to name; the youngest person refers to max(birthdate); a "clerk" role refers to role = 'Clerk'
SQL: SELECT T2.name FROM Credit AS T1 INNER JOIN Person AS T2 ON T2.person_id = T1.person_id WHERE T1.role = 'Clerk' AND T2.birthdate IS NOT NULL ORDER BY T2.birthdate LIMIT 1
Database: law_episode
Tables: Episode, Keyword, Person, Award, Credit, Vote
Columns (table index, column name): -1, *, 0, episode_id, 0, series, 0, season, 0, episode, 0, number_in_series, 0, title, 0, summary, 0, air_date, 0, episode_image, 0, rating, 0, votes, 1, episode_id, 1, keyword, 2, person_id, 2, name, 2, birthdate, 2, birth_name, 2, birth_place, 2, birth_region, 2, birth_country, 2, height_meters, 2, nickname, 3, award_id, 3, organization, 3, year, 3, award_category, 3, award, 3, series, 3, episode_id, 3, person_id, 3, role, 3, result, 4, episode_id, 4, person_id, 4, category, 4, role, 4, credited, 5, episode_id, 5, stars, 5, votes, 5, percent
Question: How many people did not enjoy the finale episode?
Evidence: did not enjoy refers to stars = 1; the finale episode refers to episode = 24
SQL: SELECT COUNT(T1.episode_id) FROM Episode AS T1 INNER JOIN Vote AS T2 ON T1.episode_id = T2.episode_id WHERE T1.episode = 24 AND T2.stars = 1
Database: law_episode
Tables: Episode, Keyword, Person, Award, Credit, Vote
Columns (table index, column name): -1, *, 0, episode_id, 0, series, 0, season, 0, episode, 0, number_in_series, 0, title, 0, summary, 0, air_date, 0, episode_image, 0, rating, 0, votes, 1, episode_id, 1, keyword, 2, person_id, 2, name, 2, birthdate, 2, birth_name, 2, birth_place, 2, birth_region, 2, birth_country, 2, height_meters, 2, nickname, 3, award_id, 3, organization, 3, year, 3, award_category, 3, award, 3, series, 3, episode_id, 3, person_id, 3, role, 3, result, 4, episode_id, 4, person_id, 4, category, 4, role, 4, credited, 5, episode_id, 5, stars, 5, votes, 5, percent
Question: List the names of all the cast members in the series.
Evidence: cast member refers to category = 'Cast'
SQL: SELECT T2.name FROM Credit AS T1 INNER JOIN Person AS T2 ON T2.person_id = T1.person_id WHERE T1.category = 'Cast'
Database: law_episode
Tables: Episode, Keyword, Person, Award, Credit, Vote
Columns (table index, column name): -1, *, 0, episode_id, 0, series, 0, season, 0, episode, 0, number_in_series, 0, title, 0, summary, 0, air_date, 0, episode_image, 0, rating, 0, votes, 1, episode_id, 1, keyword, 2, person_id, 2, name, 2, birthdate, 2, birth_name, 2, birth_place, 2, birth_region, 2, birth_country, 2, height_meters, 2, nickname, 3, award_id, 3, organization, 3, year, 3, award_category, 3, award, 3, series, 3, episode_id, 3, person_id, 3, role, 3, result, 4, episode_id, 4, person_id, 4, category, 4, role, 4, credited, 5, episode_id, 5, stars, 5, votes, 5, percent
Question: Who is the person who appeared the most in the series? Calculate in percentage how many times he or she appeared.
Evidence: who refers to name; appear the most refers to max(count(person_id)); percentage = divide(count(person_id where max(count(person_id))), count(person_id)) * 100%
SQL: SELECT T2.person_id, CAST(COUNT(T2.person_id) AS REAL) * 100 / ( SELECT COUNT(T2.person_id) AS num FROM Credit AS T1 INNER JOIN Person AS T2 ON T2.person_id = T1.person_id ) AS per FROM Credit AS T1 INNER JOIN Person AS T2 ON T2.person_id = T1.person_id GROUP BY T2.person_id ORDER BY COUNT(T2.person_id) DESC LIMIT 1
Database: law_episode
Tables: Episode, Keyword, Person, Award, Credit, Vote
Columns (table index, column name): -1, *, 0, episode_id, 0, series, 0, season, 0, episode, 0, number_in_series, 0, title, 0, summary, 0, air_date, 0, episode_image, 0, rating, 0, votes, 1, episode_id, 1, keyword, 2, person_id, 2, name, 2, birthdate, 2, birth_name, 2, birth_place, 2, birth_region, 2, birth_country, 2, height_meters, 2, nickname, 3, award_id, 3, organization, 3, year, 3, award_category, 3, award, 3, series, 3, episode_id, 3, person_id, 3, role, 3, result, 4, episode_id, 4, person_id, 4, category, 4, role, 4, credited, 5, episode_id, 5, stars, 5, votes, 5, percent
Question: Which episodes of the Law & Order have been nominated for the Primetime Emmy Awards?
Evidence: episode refers to award; the Primetime Emmy Awards refers to award_category like 'Primetime Emmy'
SQL: SELECT DISTINCT episode_id FROM Award WHERE award_category = 'Primetime Emmy'
Database: law_episode
Tables: Episode, Keyword, Person, Award, Credit, Vote
Columns (table index, column name): -1, *, 0, episode_id, 0, series, 0, season, 0, episode, 0, number_in_series, 0, title, 0, summary, 0, air_date, 0, episode_image, 0, rating, 0, votes, 1, episode_id, 1, keyword, 2, person_id, 2, name, 2, birthdate, 2, birth_name, 2, birth_place, 2, birth_region, 2, birth_country, 2, height_meters, 2, nickname, 3, award_id, 3, organization, 3, year, 3, award_category, 3, award, 3, series, 3, episode_id, 3, person_id, 3, role, 3, result, 4, episode_id, 4, person_id, 4, category, 4, role, 4, credited, 5, episode_id, 5, stars, 5, votes, 5, percent
Question: How many episodes have not won any Law & Order series awards?
Evidence: have not won any award refers to Result = 'Nominee'
SQL: SELECT COUNT(award_id) FROM Award WHERE Result = 'Nominee'
Database: law_episode
Tables: Episode, Keyword, Person, Award, Credit, Vote
Columns (table index, column name): -1, *, 0, episode_id, 0, series, 0, season, 0, episode, 0, number_in_series, 0, title, 0, summary, 0, air_date, 0, episode_image, 0, rating, 0, votes, 1, episode_id, 1, keyword, 2, person_id, 2, name, 2, birthdate, 2, birth_name, 2, birth_place, 2, birth_region, 2, birth_country, 2, height_meters, 2, nickname, 3, award_id, 3, organization, 3, year, 3, award_category, 3, award, 3, series, 3, episode_id, 3, person_id, 3, role, 3, result, 4, episode_id, 4, person_id, 4, category, 4, role, 4, credited, 5, episode_id, 5, stars, 5, votes, 5, percent
Question: What roles have not been credited at the end of the episodes?
Evidence: have not been credited refers to credited = ''
SQL: SELECT DISTINCT role FROM Credit WHERE credited = 'false'