Chinastark/bird_dataset huggingface dataset:
Database: music_platform_2
Question: What is the review with the title "Hosts bring the show down" for?
Evidence: "Hosts bring the show down" refers to title of review
SQL: SELECT title FROM podcasts WHERE podcast_id = ( SELECT podcast_id FROM reviews WHERE title = 'Hosts bring the show down' )
Database: music_platform_2
Question: Which "music" podcast has the longest title?
Evidence: music podcasts refers to category = 'music'; longest title refers to title = Max(length(title))
SQL: SELECT T2.title FROM categories AS T1 INNER JOIN podcasts AS T2 ON T2.podcast_id = T1.podcast_id WHERE T1.category = 'music' ORDER BY LENGTH(T2.title) DESC LIMIT 1
Database: music_platform_2
Question: List all the cagetories for all the podcasts with "jessica" in the title.
Evidence: podcast with 'jessica' in title refers to title like '%jessica%'
SQL: SELECT category FROM categories WHERE podcast_id IN ( SELECT podcast_id FROM podcasts WHERE title LIKE '%jessica%' )
Database: music_platform_2
Question: What is the category for the "Moist Boys" podcast?
Evidence: "Moist Boys" refers to title of podcast
SQL: SELECT category FROM categories WHERE podcast_id IN ( SELECT podcast_id FROM podcasts WHERE title = 'Moist Boys' )
Database: music_platform_2
Question: List all of the two-star reviews and their categories.
Evidence: two-stars review refers to rating = 2
SQL: SELECT T1.category FROM categories AS T1 INNER JOIN reviews AS T2 ON T2.podcast_id = T1.podcast_id WHERE T2.rating = 2
Database: music_platform_2
Question: List all the podcasts reviewed by a reviewer who has a review titled "Inspired & On Fire!".
Evidence: "Inspired & On Fire" refers to title of review
SQL: SELECT T1.title FROM podcasts AS T1 INNER JOIN reviews AS T2 ON T2.podcast_id = T1.podcast_id WHERE T2.title = 'Inspired & On Fire!'
Database: music_platform_2
Question: What are the titles and categories of all the podcasts with a review that has "Absolutely fantastic" in it?
Evidence: review refers to content; 'Absolutely fantastic' in it refers to content like '%Absolutely fantastic%'
SQL: SELECT T2.title, T1.category FROM categories AS T1 INNER JOIN podcasts AS T2 ON T2.podcast_id = T1.podcast_id INNER JOIN reviews AS T3 ON T3.podcast_id = T2.podcast_id WHERE T3.content LIKE '%Absolutely fantastic%'
Database: music_platform_2
Question: Which category has the most reviews?
Evidence: Most review refers to Max(Count(reviews.podcast_id))
SQL: SELECT T1.category FROM categories AS T1 INNER JOIN reviews AS T2 ON T2.podcast_id = T1.podcast_id GROUP BY T1.category ORDER BY COUNT(T2.podcast_id) DESC LIMIT 1
Database: music_platform_2
Question: List the urls for all the "fiction-science-fiction" podcasts.
Evidence: fiction-science-fiction podcasts refers to category = 'fiction-science-fiction'; urls refers to itunes_url
SQL: SELECT itunes_url FROM podcasts WHERE podcast_id IN ( SELECT podcast_id FROM categories WHERE category = 'fiction-science-fiction' )
Database: music_platform_2
Question: What is the content of the earliest review for the "Stuff You Should Know" podcast?
Evidence: "Stuff You Should Know" is the title of podcast; earliest refers to Min(created_at)
SQL: SELECT T2.content FROM podcasts AS T1 INNER JOIN reviews AS T2 ON T2.podcast_id = T1.podcast_id WHERE T1.title = 'Stuff You Should Know' ORDER BY T2.created_at ASC LIMIT 1
Database: music_platform_2
Question: How many reviews does "Planet Money" have?
Evidence: "Planet Money" is the title of podcast
SQL: SELECT COUNT(T2.podcast_id) FROM podcasts AS T1 INNER JOIN reviews AS T2 ON T2.podcast_id = T1.podcast_id WHERE T1.title = 'Planet Money'
Database: music_platform_2
Question: What is the average rating for the "crime-junkie" podcast?
Evidence: "crime-junkie" podcast refers to title = 'crime-junkie'; average rating = Divide (Sum(rating), Count(rating))
SQL: SELECT AVG(T2.rating) FROM podcasts AS T1 INNER JOIN reviews AS T2 ON T2.podcast_id = T1.podcast_id WHERE T1.title = 'Crime Junkie'
Database: music_platform_2
Question: What percentage of podcasts are "technology" podcasts? List all of them.
Evidence: "technology" podcast refers to category = 'technology'; percentage = Divide (Count (podcast_id (category = 'technology')), Count (podcast_id)) * 100
SQL: SELECT CAST(SUM(CASE WHEN T1.category = 'technology' THEN 1 ELSE 0 END) AS REAL) * 100 / COUNT(T2.title) OR '%' "percentage" FROM categories AS T1 INNER JOIN podcasts AS T2 ON T2.podcast_id = T1.podcast_id
Database: music_platform_2
Question: What is the content of the review under the title "really interesting!" and is created on 2018-04-24 at 12:05:16?
Evidence: "really interesting" is the title of review;  created on 2018-04-24 at 12:05:16 refers to created_at = '2018-04-24T12:05:16-07:00'
SQL: SELECT content FROM reviews WHERE title = 'really interesting!' AND created_at = '2018-04-24T12:05:16-07:00'
Database: music_platform_2
Question: Which category is the podcast "Scaling Global" under?
Evidence: "Scaling Global" is the title of podcast
SQL: SELECT category FROM categories WHERE podcast_id IN ( SELECT podcast_id FROM podcasts WHERE title = 'Scaling Global' )
Database: music_platform_2
Question: Please list the titles of all the podcasts under the category "arts-performing-arts".
Evidence: category 'arts-performing-arts' refers to category = 'arts-performing-arts';
SQL: SELECT DISTINCT T2.title FROM categories AS T1 INNER JOIN podcasts AS T2 ON T2.podcast_id = T1.podcast_id WHERE T1.category = 'arts-performing-arts'
Database: music_platform_2
Question: How many reviews are created for the podcast "Scaling Global" under?
Evidence: "Scaling Global" is the title of podcast
SQL: SELECT COUNT(T2.content) FROM podcasts AS T1 INNER JOIN reviews AS T2 ON T2.podcast_id = T1.podcast_id WHERE T1.title = 'Scaling Global'
Database: music_platform_2
Question: Among the reviews for the podcast "Please Excuse My Dead Aunt Sally", how many of them are made in the year 2019?
Evidence: "Please Excuse My Dead Aunt Sally" is the title of podcast; made in the year 2019 refers to created_at like '2019%'
SQL: SELECT COUNT(T2.created_at) FROM podcasts AS T1 INNER JOIN reviews AS T2 ON T2.podcast_id = T1.podcast_id WHERE T1.title = 'Please Excuse My Dead Aunt Sally' AND T2.created_at LIKE '2019-%'
Database: music_platform_2
Question: Please list the titles of the podcasts for which the author whose ID is F7E5A318989779D has written a review.
Evidence: author whose ID is F7E5A318989779D refers to author_id = 'F7E5A318989779D'
SQL: SELECT T2.title FROM podcasts AS T1 INNER JOIN reviews AS T2 ON T2.podcast_id = T1.podcast_id WHERE T2.author_id = 'F7E5A318989779D'
Database: music_platform_2
Question: How many ratings of 5 have been given to the podcast "Please Excuse My Dead Aunt Sally"?
Evidence: rating of 5 refers to rating = 5; 'Please Excuse My Dead Aunt Sally' is the title of podcast
SQL: SELECT COUNT(T2.rating) FROM podcasts AS T1 INNER JOIN reviews AS T2 ON T2.podcast_id = T1.podcast_id WHERE T1.title = 'Please Excuse My Dead Aunt Sally' AND T2.rating = 5
Database: music_platform_2
Question: What is the average rating of the podcast "Please Excuse My Dead Aunt Sally"?
Evidence: "Please Excuse My Dead Aunty Sally" is the title of podcast; Average rating = Divide (Sum(rating), Count(rating))
SQL: SELECT AVG(T2.rating) FROM podcasts AS T1 INNER JOIN reviews AS T2 ON T2.podcast_id = T1.podcast_id WHERE T1.title = 'Please Excuse My Dead Aunt Sally'
Database: university
Question: How many universities have at least 80,000 students in the year 2011?
Evidence: have at least 80,000 students refers to num_students > 8000; year = 2011
SQL: SELECT COUNT(*) FROM university_year WHERE num_students > 80000 AND year = 2011
Database: university
Question: What is the ranking system ID of the award criteria?
Evidence: award criteria refers to criteria_name = 'Award';
SQL: SELECT ranking_system_id FROM ranking_criteria WHERE criteria_name = 'Award'
Database: university
Question: How many state universities are there?
Evidence: state universities refers to university_name LIKE '%State%';
SQL: SELECT COUNT(*) FROM university WHERE university_name LIKE '%State%'
Database: university
Question: What is the student staff ratio of the university with the highest student staff ratio of all time?
Evidence: highest student staff ratio refers to max(student_staff_ratio)
SQL: SELECT MAX(student_staff_ratio) FROM university_year WHERE student_staff_ratio = ( SELECT MAX(student_staff_ratio) FROM university_year )
Database: university
Question: How many criteria belong to ranking system ID 3?
SQL: SELECT COUNT(id) FROM ranking_criteria WHERE ranking_system_id = 3
Database: university
Question: What is the ID of the university that has only 1% of international students between 2011 to 2015?
Evidence: has only 1% of international students refers to pct_international_students = 1; between 2011 to 2015 refers to year BETWEEN 2011 AND 2015; ID of university refers to university_id
SQL: SELECT university_id FROM university_year WHERE pct_international_students = 1 AND year BETWEEN 2011 AND 2015
Database: university
Question: Give the name of the country that has the most universities.
Evidence: has the most universities refers to MAX(COUNT(id)); name of the country refers to country_name
SQL: SELECT T2.country_name FROM university AS T1 INNER JOIN country AS T2 ON T1.country_id = T2.id GROUP BY T2.country_name ORDER BY COUNT(T1.university_name) DESC LIMIT 1
Database: university
Question: What is the name of the university that had the highest number of international students for 6 consecutive years?
Evidence: had the highest number of international students refers to max(pct_international_students); for 6 consecutive years refers to count(SUBTRACT(year, rm)) > = 6; name of university refers to university_name;
SQL: SELECT T2.university_name FROM university_year AS T1 INNER JOIN university AS T2 ON T1.university_id = T2.id ORDER BY T1.pct_international_students DESC LIMIT 1
Database: university
Question: In 2014, what is the name of the university which was considered a leader in the publications rank?
Evidence: In 2014 refers to year = 2014; leader refers to MAX(score); in the publications rank refers to criteria_name = 'Publications Rank'; name of university refers to university_name;
SQL: SELECT T3.university_name FROM ranking_criteria AS T1 INNER JOIN university_ranking_year AS T2 ON T1.id = T2.ranking_criteria_id INNER JOIN university AS T3 ON T3.id = T2.university_id WHERE T1.criteria_name = 'Publications Rank' AND T2.year = 2014 AND T1.id = 17 ORDER BY T2.score DESC LIMIT 1
Database: university
Question: What is the name of the university that has the lowest number of students of all time?
Evidence: has the lowest number of students refers to min(num_students); name of the university refers to university_name
SQL: SELECT T2.university_name FROM university_year AS T1 INNER JOIN university AS T2 ON T1.university_id = T2.id ORDER BY T1.num_students LIMIT 1
Database: university
Question: How many universities are there in the United States of America?
Evidence: in the United States of America refers to country_name = 'United States of America';
SQL: SELECT COUNT(*) FROM university AS T1 INNER JOIN country AS T2 ON T1.country_id = T2.id WHERE T2.country_name = 'United States of America'
Database: university
Question: In 2016, what is the name of the university in Australia with the highest score in Citations criteria?
Evidence: In 2016 refers to year = 2016; name of the university refers to university_name; in Australia refers to country_name = 'Australia'; in Citations criteria refers to criteria_name = 'Citations'; highest score refers to MAX(score)
SQL: SELECT T3.university_name FROM ranking_criteria AS T1 INNER JOIN university_ranking_year AS T2 ON T1.id = T2.ranking_criteria_id INNER JOIN university AS T3 ON T3.id = T2.university_id INNER JOIN country AS T4 ON T4.id = T3.country_id WHERE T1.criteria_name = 'Citations' AND T2.year = 2016 AND T1.id = 4 AND T4.country_name = 'Australia' ORDER BY T2.score DESC LIMIT 1
Database: university
Question: How many universities scored 0 in Awards between 2005 to 2015?
Evidence: between 2005 to 2015 refers to year BETWEEN 2005 AND 2015; scored 0 refers to score = 0; in Awards refers to criteria_name = 'Award'
SQL: SELECT COUNT(*) FROM ranking_criteria AS T1 INNER JOIN university_ranking_year AS T2 ON T1.id = T2.ranking_criteria_id WHERE T1.criteria_name = 'Award' AND T2.year BETWEEN 2005 AND 2015 AND T2.score = 0
Database: university
Question: Which country is the University of Oxford located?
Evidence: University of Oxford refers to university_name = 'University of Oxford'; which country refers to country_name
SQL: SELECT T2.country_name FROM university AS T1 INNER JOIN country AS T2 ON T1.country_id = T2.id WHERE university_name = 'University of Oxford'
Database: university
Question: How many times did the Yale University achieve a score of no less than 10 in the Quality of Education Rank?
Evidence: Yale University refers to university_name = 'Yale University'; a score of no less than 10 refers to score > = 10; in the Quality of Education Rank refers to criteria_name = 'Quality of Education Rank'
SQL: SELECT COUNT(*) FROM ranking_criteria AS T1 INNER JOIN university_ranking_year AS T2 ON T1.id = T2.ranking_criteria_id INNER JOIN university AS T3 ON T3.id = T2.university_id WHERE T3.university_name = 'Yale University' AND T2.score >= 10 AND T1.criteria_name = 'Quality of Education Rank'
Database: university
Question: What are the names of the criteria under Center for World University Rankings?
Evidence: names of the criteria refers to criteria_name; under Center for World University Rankings refers to system_name = 'Center for World University Rankings';
SQL: SELECT T2.criteria_name FROM ranking_system AS T1 INNER JOIN ranking_criteria AS T2 ON T1.id = T2.ranking_system_id WHERE T1.system_name = 'Center for World University Rankings'
Database: university
Question: List the names of all the universities that have no less than 50,000 students in the year 2012.
Evidence: have no less than 50,000 students refers to num_students > 50000; name of university refers to university_name;
SQL: SELECT T2.university_name FROM university_year AS T1 INNER JOIN university AS T2 ON T1.university_id = T2.id WHERE T1.num_students > 50000 AND T1.year = 2012
Database: university
Question: Between 2011 to 2016, in which countries can you find the universities where at least 50% of its students are international students?
Evidence: Between 2011 to 2016 refers to year BETWEEN 2011 AND 2016; at least 50% of its students are international students refers to pct_international_students > 50; which country refers to country_name
SQL: SELECT DISTINCT T3.country_name FROM university AS T1 INNER JOIN university_year AS T2 ON T1.id = T2.university_id INNER JOIN country AS T3 ON T3.id = T1.country_id WHERE T2.pct_international_students > 50 AND T2.year BETWEEN 2011 AND 2016
Database: university
Question: How many universities have no less than 20,000 female students in 2016? Identify how many of the said universities are located in the United States of America.
Evidence: have no less than 20,000 female students refers to DIVIDE(MULTIPLY(pct_female_students, num_students), 100) > 20000; in 2016 refers to year = 2016; located in the United States of America refers to country_name = 'United States of America'
SQL: SELECT COUNT(*) , SUM(CASE WHEN T3.country_name = 'United States of America' THEN 1 ELSE 0 END) AS nums_in_usa FROM university AS T1 INNER JOIN university_year AS T2 ON T1.id = T2.university_id INNER JOIN country AS T3 ON T3.id = T1.country_id WHERE T2.year = 2016 AND T2.num_students * T2.pct_female_students / 100 > 20000
Database: university
Question: What are the names of the top 5 universities with the highest number of international students?
Evidence: highest number of international students refers to MAX(DIVIDE(MULTIPLY(num_students, pct_international_students), 100)); name of university refers to university_name;
SQL: SELECT DISTINCT T2.university_name FROM university_year AS T1 INNER JOIN university AS T2 ON T1.university_id = T2.id ORDER BY (CAST(T1.num_students * T1.pct_international_students AS REAL) / 100) DESC LIMIT 5
Database: university
Question: What is the university ID of the university with the largest student staff ratio?
Evidence: the largest student staff ratio refers to max(student_staff_ratio)
SQL: SELECT university_id FROM university_year ORDER BY student_staff_ratio DESC LIMIT 1
Database: university
Question: Give the year where a university had the lowest number of students.
Evidence: had the lowest number of students refers to MIN(num_students)
SQL: SELECT year FROM university_year ORDER BY num_students ASC LIMIT 1
Database: university
Question: Compute the average percentage of female students.
Evidence: average percentage of female students refers to avg(pct_female_students)
SQL: SELECT AVG(pct_female_students) FROM university_year
Database: university
Question: Provide the number of international students and number of students in 2013 in university ID 20.
Evidence: number of international students refers to DIVIDE(MULTIPLY(pct_international_students, num_students), 100); in 2013 refers to year = 2013
SQL: SELECT pct_international_students * num_students, num_students FROM university_year WHERE year = 2013 AND university_id = 20
Database: university
Question: What is the university ID of Harvard University?
Evidence: of Harvard University refers to university_name = 'Harvard University';
SQL: SELECT id FROM university WHERE university_name = 'Harvard University'
Database: university
Question: List the university ID of the university that scored 100 in 2011.
Evidence: in 2011 refers to year = 2011; score = 100
SQL: SELECT university_id FROM university_ranking_year WHERE score = 100 AND year = 2011
Database: university
Question: Provide the ranking system of the ranking criteria named Quality of Education Rank.
Evidence: criteria named Quality of Education Rank refers to criteria_name = 'Quality of Education Rank'; ranking system refers to system_name;
SQL: SELECT T1.system_name FROM ranking_system AS T1 INNER JOIN ranking_criteria AS T2 ON T1.id = T2.ranking_system_id WHERE T2.criteria_name = 'Quality of Education Rank'
Database: university
Question: What is the student staff ratio of Harvard University in 2012?
Evidence: Harvard University refers to university_name = 'Harvard University'; in 2012 refers to year = 2012
SQL: SELECT T1.student_staff_ratio FROM university_year AS T1 INNER JOIN university AS T2 ON T1.university_id = T2.id WHERE T2.university_name = 'Harvard University' AND T1.year = 2012
Database: university
Question: Give the location of the university ID 112.
Evidence: location refers to country_name
SQL: SELECT T2.country_name FROM university AS T1 INNER JOIN country AS T2 ON T1.country_id = T2.id WHERE T1.id = 112
Database: university
Question: Calculate the total number of students in universities located in Sweden.
Evidence: located in Sweden refers to country_name = 'Sweden'; number of students refers to num_students
SQL: SELECT SUM(T2.num_students) FROM university AS T1 INNER JOIN university_year AS T2 ON T1.id = T2.university_id INNER JOIN country AS T3 ON T3.id = T1.country_id WHERE T3.country_name = 'Sweden'
Database: university
Question: What is the ranking criteria ID of Brown University in 2014?
Evidence: Brown University refers to university_name = 'Brown University'; in 2014 refers to year = 2014
SQL: SELECT T1.ranking_criteria_id FROM university_ranking_year AS T1 INNER JOIN university AS T2 ON T1.university_id = T2.id WHERE T2.university_name = 'Brown University' AND T1.year = 2014
Database: university
Question: List the name of universities located in Spain.
Evidence: name of universities refers to university_name; located in Spain refers to country_name = 'Spain';
SQL: SELECT T1.university_name FROM university AS T1 INNER JOIN country AS T2 ON T1.country_id = T2.id WHERE T2.country_name = 'Spain'
Database: university
Question: What is the criteria name of the university ID 32 in 2015?
Evidence: in 2015 refers to year = 2015
SQL: SELECT T1.criteria_name FROM ranking_criteria AS T1 INNER JOIN university_ranking_year AS T2 ON T1.id = T2.ranking_criteria_id WHERE T2.university_id = 32 AND T2.year = 2015
Database: university
Question: Compute the average score of the university located in Brazil.
Evidence: average score refers to avg(score); located in Brazil refers to country_name = 'Brazil';
SQL: SELECT AVG(T2.score) FROM university AS T1 INNER JOIN university_ranking_year AS T2 ON T1.id = T2.university_id INNER JOIN country AS T3 ON T3.id = T1.country_id WHERE T3.country_name = 'Brazil'
Database: university
Question: In which country does the most populated university in 2014 located ?
Evidence: the most populated university refers to max(num_students); in 2014 refers to year = 2014
SQL: SELECT T2.country_id FROM university_year AS T1 INNER JOIN university AS T2 ON T1.university_id = T2.id WHERE T1.year = 2014 ORDER BY T1.num_students DESC LIMIT 1
Database: university
Question: Give the score and number of international students in university ID 100 in 2015.
Evidence: number of international students refers to DIVIDE(MULTIPLY(num_students, pct_international_students), 100); in 2015 refers to year = 2015
SQL: SELECT CAST(T1.num_students * T1.pct_international_students AS REAL) / 100, T2.score FROM university_year AS T1 INNER JOIN university_ranking_year AS T2 ON T1.university_id = T2.university_id WHERE T2.year = 2015 AND T1.university_id = 100
Database: university
Question: What is the student population of the university that scored 98 in 2013?
Evidence: student population refers to num_students; in 2013 refers to year = 2013
SQL: SELECT SUM(T1.num_students) FROM university_year AS T1 INNER JOIN university_ranking_year AS T2 ON T1.university_id = T2.university_id WHERE T2.score = 98 AND T1.year = 2013
Database: university
Question: List the criteria names under the ranking system called Center for World University Ranking.
Evidence: ranking system called Center for World University Ranking refers to system_name = 'Center for World University Rankings';
SQL: SELECT T2.criteria_name FROM ranking_system AS T1 INNER JOIN ranking_criteria AS T2 ON T1.id = T2.ranking_system_id WHERE T1.system_name = 'Center for World University Rankings'
Database: university
Question: Provide the country name of universities with the number of students greater than 98% of the average student population of all universities in 2013.
Evidence: number of students greater than 98% of the average student population of all universities refers to num_students >  MULTPLY(num_students, 0.98); in 2013 refers to year = 2013
SQL: SELECT DISTINCT T3.country_name FROM university AS T1 INNER JOIN university_year AS T2 ON T1.id = T2.university_id INNER JOIN country AS T3 ON T3.id = T1.country_id WHERE T2.year = 2013 AND T2.num_students * 100 > ( SELECT AVG(num_students) FROM university_year ) * 98
Database: university
Question: Among universities that score below 80 in 2015, what is the percentage of international students?
Evidence: score below 80 refers to score < 80; in 2015 refers to year 2015; percentage of international students refers to DIVIDE(SUM(DIVIDE(MULTIPLY(num_students, pct_international_students), 100)), SUM(num_students))
SQL: SELECT SUM(CAST(T1.num_students * T1.pct_international_students AS REAL) / 100) / COUNT(*) * 100 FROM university_year AS T1 INNER JOIN university_ranking_year AS T2 ON T1.university_id = T2.university_id WHERE T2.score < 80 AND T1.year = 2015
Database: university
Question: How many students attended universities were there in 2011?
Evidence: in 2011 refers to year = 2011;
SQL: SELECT SUM(num_students) FROM university_year WHERE year = 2011
Database: university
Question: Among all universities, how many female students were there in 2011?
Evidence: in 2011 refers to year = 2011; female students refers to SUM(DIVIDE(MULTIPLY(num_students, pct_female_students), 100))
SQL: SELECT SUM(CAST(num_students * pct_female_students AS REAL) / 100) FROM university_year WHERE year = 2011