db_id
stringclasses
69 values
question
stringlengths
24
325
evidence
stringlengths
1
673
SQL
stringlengths
23
804
schema
stringclasses
69 values
university
Which country is the University of Oxford located?
University of Oxford refers to university_name = 'University of Oxford'; which country refers to country_name
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 name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
How many times did the Yale University achieve a score of no less than 10 in the Quality of Education Rank?
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'
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 name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
What are the names of the criteria under Center for World University Rankings?
names of the criteria refers to criteria_name; under Center for World University Rankings refers to system_name = 'Center for World University Rankings';
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 name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
List the names of all the universities that have no less than 50,000 students in the year 2012.
have no less than 50,000 students refers to num_students > 50000; name of university refers to university_name;
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 name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
Between 2011 to 2016, in which countries can you find the universities where at least 50% of its students are international students?
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
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 name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
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.
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'
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 name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
What are the names of the top 5 universities with the highest number of international students?
highest number of international students refers to MAX(DIVIDE(MULTIPLY(num_students, pct_international_students), 100)); name of university refers to university_name;
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 name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
What is the university ID of the university with the largest student staff ratio?
the largest student staff ratio refers to max(student_staff_ratio)
SELECT university_id FROM university_year ORDER BY student_staff_ratio DESC LIMIT 1
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
Give the year where a university had the lowest number of students.
had the lowest number of students refers to MIN(num_students)
SELECT year FROM university_year ORDER BY num_students ASC LIMIT 1
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
Compute the average percentage of female students.
average percentage of female students refers to avg(pct_female_students)
SELECT AVG(pct_female_students) FROM university_year
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
Provide the number of international students and number of students in 2013 in university ID 20.
number of international students refers to DIVIDE(MULTIPLY(pct_international_students, num_students), 100); in 2013 refers to year = 2013
SELECT pct_international_students * num_students, num_students FROM university_year WHERE year = 2013 AND university_id = 20
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
What is the university ID of Harvard University?
of Harvard University refers to university_name = 'Harvard University';
SELECT id FROM university WHERE university_name = 'Harvard University'
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
List the university ID of the university that scored 100 in 2011.
in 2011 refers to year = 2011; score = 100
SELECT university_id FROM university_ranking_year WHERE score = 100 AND year = 2011
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
Provide the ranking system of the ranking criteria named Quality of Education Rank.
criteria named Quality of Education Rank refers to criteria_name = 'Quality of Education Rank'; ranking system refers to system_name;
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 name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
What is the student staff ratio of Harvard University in 2012?
Harvard University refers to university_name = 'Harvard University'; in 2012 refers to year = 2012
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 name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
Give the location of the university ID 112.
location refers to country_name
SELECT T2.country_name FROM university AS T1 INNER JOIN country AS T2 ON T1.country_id = T2.id WHERE T1.id = 112
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
Calculate the total number of students in universities located in Sweden.
located in Sweden refers to country_name = 'Sweden'; number of students refers to num_students
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 name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
What is the ranking criteria ID of Brown University in 2014?
Brown University refers to university_name = 'Brown University'; in 2014 refers to year = 2014
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 name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
List the name of universities located in Spain.
name of universities refers to university_name; located in Spain refers to country_name = 'Spain';
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 name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
What is the criteria name of the university ID 32 in 2015?
in 2015 refers to year = 2015
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 name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
Compute the average score of the university located in Brazil.
average score refers to avg(score); located in Brazil refers to country_name = 'Brazil';
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 name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
In which country does the most populated university in 2014 located ?
the most populated university refers to max(num_students); in 2014 refers to year = 2014
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 name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
Give the score and number of international students in university ID 100 in 2015.
number of international students refers to DIVIDE(MULTIPLY(num_students, pct_international_students), 100); in 2015 refers to year = 2015
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 name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
What is the student population of the university that scored 98 in 2013?
student population refers to num_students; in 2013 refers to year = 2013
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 name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
List the criteria names under the ranking system called Center for World University Ranking.
ranking system called Center for World University Ranking refers to system_name = 'Center for World University Rankings';
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 name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
Provide the country name of universities with the number of students greater than 98% of the average student population of all universities in 2013.
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
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 name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
Among universities that score below 80 in 2015, what is the percentage of international students?
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))
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 name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
How many students attended universities were there in 2011?
in 2011 refers to year = 2011;
SELECT SUM(num_students) FROM university_year WHERE year = 2011
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
Among all universities, how many female students were there in 2011?
in 2011 refers to year = 2011; female students refers to SUM(DIVIDE(MULTIPLY(num_students, pct_female_students), 100))
SELECT SUM(CAST(num_students * pct_female_students AS REAL) / 100) FROM university_year WHERE year = 2011
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
What is the student staff ratio at the university with the greatest student staff ratio of all time?
greatest student staff ratio of all time refers to max(student_staff_ratio)
SELECT MAX(student_staff_ratio) FROM university_year ORDER BY student_staff_ratio DESC LIMIT 1
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
What is the university ID with the most students in 2011?
most students refers to MAX(num_students), in 2011 refers to year = 2011
SELECT university_id FROM university_year WHERE year = 2011 ORDER BY num_students DESC LIMIT 1
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
How many institutions with over 50,000 students in 2011 had a percentage of oversea students of more than 10%?
institutions with over 50,000 students refers to num_students > 50000; in 2011 refers to year = 2011; percentage of oversea students of more than 10% refers to pct_international_students > 10;
SELECT COUNT(*) FROM university_year WHERE year = 2011 AND num_students > 50000 AND pct_international_students > 10
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
Provide the ID of the university with the highest percentage of female students in 2012.
in 2012 refers to year = 2012; highest percentage of female students  refers to MAX(pct_female_students); ID of the university refers to university_id
SELECT university_id FROM university_year WHERE year = 2012 ORDER BY pct_female_students DESC LIMIT 1
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
Which university had the highest reputation in 2012?
had the highest reputation refers to MAX(score), in 2012 refers to year = 2012; which university refers to university_name;
SELECT T2.university_name FROM university_ranking_year AS T1 INNER JOIN university AS T2 ON T1.university_id = T2.id WHERE T1.year = 2012 ORDER BY T1.score DESC LIMIT 1
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
Name the university that had the most students in 2011.
in 2011 refers to year = 2011; had the most students refers to MAX(num_students); name of university refers to university_name;
SELECT T2.university_name FROM university_year AS T1 INNER JOIN university AS T2 ON T1.university_id = T2.id WHERE T1.year = 2011 ORDER BY T1.num_students DESC LIMIT 1
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
Indicate the university's name with the highest ranking score in Teaching.
university's name refers to university_name; highest ranking score refers to MAX(score); in Teaching refers to criteria_name = 'Teaching'
SELECT T1.university_name FROM university AS T1 INNER JOIN university_ranking_year AS T2 ON T1.id = T2.university_id INNER JOIN ranking_criteria AS T3 ON T3.id = T2.ranking_criteria_id WHERE T3.criteria_name = 'Teaching' ORDER BY T2.score DESC LIMIT 1
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
What is the percentage of Harvard university's international students in 2011?
Harvard university's refers to university_name = 'Harvard University'; in 2011 refers to year = 2011; percentage of Harvard university's international students refers to pct_international_students
SELECT T1.pct_international_students FROM university_year AS T1 INNER JOIN university AS T2 ON T1.university_id = T2.id WHERE T1.year = 2011 AND T2.university_name = 'Harvard University'
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
How many female students were there at Stanford University in 2011?
in 2011 refers to year 2011; female students refers to DIVIDE(MULTIPLY(pct_female_students, num_students), 100); Stanford University refers to university_name = 'Stanford University';
SELECT CAST(T1.num_students * T1.pct_female_students AS REAL) / 100 FROM university_year AS T1 INNER JOIN university AS T2 ON T1.university_id = T2.id WHERE T1.year = 2011 AND T2.university_name = 'Stanford University'
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
In which nation is Harvard University located?
Harvard University refers to university_name = 'Harvard University'; nation refers to country_name
SELECT T2.country_name FROM university AS T1 INNER JOIN country AS T2 ON T1.country_id = T2.id WHERE T1.university_name = 'Harvard University'
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
What is the name of the ranking system for Teaching criteria?
Teaching criteria refers to criteria_name = 'Teaching'; name of the ranking system refers to system_name
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 = 'Teaching'
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
Name the most famous university in Argentina.
in Argentina refers to country_name = 'Argentina';  most famous refers to MAX(SUM(score))
SELECT T1.university_name 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 = 'Argentina' GROUP BY T1.university_name ORDER BY SUM(T2.score) DESC LIMIT 1
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
In Argentina, how many universities are there?
In Argentina refers to country_name = 'Argentina';
SELECT COUNT(*) FROM university AS T1 INNER JOIN country AS T2 ON T1.country_id = T2.id WHERE T2.country_name = 'Argentina'
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
Which universities have more than 100,000 students in 2011?
in 2011 refers to year 2011; more than 100,000 students refers to num_students > 100000; which university refers to university_name;
SELECT T2.university_name FROM university_year AS T1 INNER JOIN university AS T2 ON T1.university_id = T2.id WHERE T1.year = 2011 AND T1.num_students > 100000
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
How many criteria are associated with ranking system Center for World University Rankings?
ranking system Center for World University Rankings refers to system_name = 'Center for World University Rankings';
SELECT COUNT(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 name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
How many students at the university earned a score of 90 in 2011?
in 2011 refers to year 2011; earned a score of 90 refers to score = 90;
SELECT COUNT(*) FROM university_year AS T1 INNER JOIN university_ranking_year AS T2 ON T1.university_id = T2.university_id WHERE T2.score = 90 AND T1.year = 2011
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
What are the top three universities with the most international students?
most international students refers to MAX(SUM(DIVIDE(MULTIPLE(pct_international_students, num_students), 100))); name of university refers to university_name;
SELECT DISTINCT T2.university_name FROM university_year AS T1 INNER JOIN university AS T2 ON T1.university_id = T2.id GROUP BY T2.university_name ORDER BY SUM(T1.num_students * T1.pct_international_students / 100) DESC LIMIT 3
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
What is the difference in overall student enrollment and international student enrollment at the Harvard university from 2011 to 2012?
Harvard University refers to university_name = 'Harvard University'; difference in overall student enrollment and international student refers to SUBTRACT(SUM(num_students), SUM(DIVIDE(MULTIPLY(pct_international_students, num_students), 100))); from 2011 to 2012 refers to year BETWEEN 2011 AND 2012
SELECT SUM(T1.num_students) - SUM(CAST(T1.num_students * T1.pct_international_students AS REAL) / 100) 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 BETWEEN 2011 AND 2012
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
How many universities had over 30000 students in 2011?
in 2011 refers to year 2011; had over 30000 students refers to num_students > 30000;
SELECT COUNT(*) FROM university_year WHERE year = 2011 AND num_students > 30000
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
What is the country ID of the University of Tokyo?
University of Tokyo refers to university_name = 'University of Tokyo';
SELECT country_id FROM university WHERE university_name = 'University of Tokyo'
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
Provide the ranking system ID of the Center for World University Rankings.
the Center for World University Rankings refers to system_name = 'Center for World University Rankings';
SELECT id FROM ranking_system WHERE system_name = 'Center for World University Rankings'
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
What is the ID of the Publications Rank criteria?
Publications Rank criteria refers to criteria_name = 'Publications Rank';
SELECT id FROM ranking_criteria WHERE criteria_name = 'Publications Rank'
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
How many universities had above 30% of international students in 2013?
had above 30% of international students refers to pct_international_students > 30; in 2013 refers to year = 2013
SELECT COUNT(*) FROM university_year WHERE pct_international_students > 30 AND year = 2013
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
How many universities got less than 50 scores under ranking criteria ID 6 in 2011?
in 2011 refers to year 2011; less than 50 scores refers to score < 50;
SELECT COUNT(*) FROM university_ranking_year WHERE ranking_criteria_id = 6 AND year = 2011 AND score < 50
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
Provide the number of students at Yale University in 2016.
number of students refers to num_students; Yale University refers to university_name = 'Yale University'; in 2016 refers to year = 2016
SELECT T1.num_students FROM university_year AS T1 INNER JOIN university AS T2 ON T1.university_id = T2.id WHERE T2.university_name = 'Yale University' AND T1.year = 2016
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
List the universities in Denmark.
in Denmark refers to country_name = 'Denmark'; name of university refers to university_name;
SELECT T1.university_name FROM university AS T1 INNER JOIN country AS T2 ON T1.country_id = T2.id WHERE T2.country_name = 'Denmark'
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
Provide the number of staff at the University of Auckland in 2015.
University of Auckland refers to university_name = 'University of Auckland'; in 2015 refers to year = 2015; number of staff refers to DIVIDE(num_students, student_staff_ratio)
SELECT CAST(SUM(T1.num_students) AS REAL) / SUM(T1.student_staff_ratio) FROM university_year AS T1 INNER JOIN university AS T2 ON T1.university_id = T2.id WHERE T2.university_name = 'University of Auckland' AND T1.year = 2015
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
Which country has the University of São Paulo?
the University of São Paulo refers to university_name = 'University of São Paulo'; which country refers to country_name;
SELECT T2.country_name FROM university AS T1 INNER JOIN country AS T2 ON T1.country_id = T2.id WHERE T1.university_name = 'University of São Paulo'
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
How many international students attended Harvard University in 2012?
Harvard University refers to university_name = 'Harvard University'; international students refers to DIVIDE(MULTIPLY(num_students, pct_international_students), 100); in 2012 refers to year = 2012
SELECT CAST(T2.num_students * T2.pct_international_students AS REAL) / 100 FROM university AS T1 INNER JOIN university_year AS T2 ON T1.id = T2.university_id WHERE T1.university_name = 'Harvard University' AND T2.year = 2012
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
Calculate the number of female students at Arizona State University in 2014.
female students refers to DIVIDE(MULTIPLY(pct_female_students, num_students), 100); at Arizona State University refers to university_name = 'Arizona State University'; in 2014 refers to year = 2014
SELECT CAST(T2.num_students * T2.pct_female_students AS REAL) / 100 FROM university AS T1 INNER JOIN university_year AS T2 ON T1.id = T2.university_id WHERE T1.university_name = 'Arizona State University' AND T2.year = 2014
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
Provide the universities which got the highest scores.
got the highest scores refers to MAX(SUM(score))
SELECT T1.university_name FROM university AS T1 INNER JOIN university_ranking_year AS T2 ON T1.id = T2.university_id GROUP BY T1.university_name ORDER BY SUM(T2.score) DESC LIMIT 1
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
List the ranking criteria under the Shanghai Ranking system.
Shanghai Ranking system refers to system_name = 'Shanghai Ranking'; ranking criteria refers to criteria_name
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 = 'Shanghai Ranking'
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
In 2011, which university got the lowest score in teaching criteria?
in 2011 refers to year 2011; got the lowest score refers to MIN(score), teaching criteria refers to criteria_name = 'Teaching'
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 = 'Teaching' AND T2.year = 2011 ORDER BY T2.score ASC LIMIT 1
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
Provide the ranking system name for the "Quality of Education Rank" criteria.
the "Quality of Education Rank" criteria refers to criteria_name = 'Quality of Education Rank'; ranking system refers to system_name
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 name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
How many percent of universities got a score above 80 under International criteria in 2016? Among them, name the university which got the highest score.
got a score above 80 refers to score > 80; under International criteria refers to criteria_name = 'International'; in 2016 refers to year = 2016; highest score refers to MAX(score)
SELECT CAST(SUM(CASE WHEN T2.score > 80 THEN 1 ELSE 0 END) AS REAL) / COUNT(*), ( 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 = 'International' AND T2.year = 2016 AND T2.score > 80 ORDER BY T2.score DESC LIMIT 1 ) AS max 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 = 'International' AND T2.year = 2016
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
Provide the ranking criteria and scores in 2005 that were received by Harvard University.
Harvard University refers to university_name = 'Harvard University'; in 2005 refers to year = 2005; ranking criteria refers to criteria_name;
SELECT T1.criteria_name, T2.score 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 = 'Harvard University' AND T2.year = 2005
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
Calculate the average score per university under Alumni criteria in 2008.
under Alumni criteria refers to criteria_name = 'Alumni'; in 2008 refers to year = 2008; average score refers to DIVIDE(SUM(score), COUNT(university_id))
SELECT AVG(T2.score) FROM ranking_criteria AS T1 INNER JOIN university_ranking_year AS T2 ON T1.id = T2.ranking_criteria_id WHERE T1.criteria_name = 'Alumni' AND T2.year = 2008
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
Name the university and country which had the highest number of international students in 2015.
highest number of international students refers to MAX(DIVIDE(MULTIPLY(num_students, pct_international_students), 100)); in 2015 refers to year = 2015; name of university refers to university_name;
SELECT T1.university_name, 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 = 2015 ORDER BY T2.num_students DESC LIMIT 1
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
How many students were there in university ID 1 in 2011?
in 2011 refers to year 2011;
SELECT num_students FROM university_year WHERE year = 2011 AND university_id = 1
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
What is the ID of the university with the most students in 2011?
in 2011 refers to year 2011; with the most students refers to MAX(num_students); ID of the university refers to university_id
SELECT university_id FROM university_year WHERE year = 2011 ORDER BY num_students DESC LIMIT 1
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
Please list the IDs of the universities with a student staff ratio of over 15 in 2011.
in 2011 refers to year 2011; student staff ratio of over 15 refers to student_staff_ratio > 15; ID of the university refers to university_id
SELECT university_id FROM university_year WHERE year = 2011 AND student_staff_ratio > 15
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
Among the universities with over 20000 students in 2011, how many of them have an international students percentage of over 25% in the same year?
in 2011 refers to year 2011; with over 20000 students refers to num_students > 20000; international students percentage of over 25% refers to pct_international_students > 25;
SELECT COUNT(*) FROM university_year WHERE year = 2011 AND pct_international_students > 25 AND num_students > 20000
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
Please list the IDs of the universities with the top 3 female students percentage in 2011.
in 2011 refers to year 2011; top 3 female students percentage refers to MAX(pct_female_students) LIMIT 3; ID of the university refers to university_id
SELECT university_id FROM university_year WHERE year = 2011 ORDER BY pct_female_students DESC LIMIT 3
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
In which year did university ID 1 have the most students?
have the most students refers to MAX(num_students)
SELECT year FROM university_year WHERE university_id = 1 ORDER BY num_students DESC LIMIT 1
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
How many students did Harvard University have in 2011?
in 2011 refers to year 2011; Harvard University refers to university_name = 'Harvard University';
SELECT T1.num_students 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 = 2011
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
What is the name of the university with the most international students in 2011?
in 2011 refers to year 2011; the most international students refers to MAX(DIVIDE(MULTIPLY(num_students,  pct_international_students), 100)); name of university refers to university_id
SELECT T2.university_name FROM university_year AS T1 INNER JOIN university AS T2 ON T1.university_id = T2.id WHERE T1.year = 2011 ORDER BY T1.pct_international_students DESC LIMIT 1
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
Please list the names of all the universities in Australia.
in Australia refers to country_name = 'Australia'; name of university refers to university_name
SELECT T1.university_name FROM university AS T1 INNER JOIN country AS T2 ON T1.country_id = T2.id WHERE T2.country_name = 'Australia'
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
Among the universities in Australia, how many of them have more than 15000 students in 2011?
in 2011 refers to year 2011; have more than 15000 students refers to num_students > 15000; in Australia refers to country_name = 'Australia';
SELECT COUNT(*) 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 = 'Australia' AND T2.year = 2011 AND T2.num_students > 15000
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
Which country is Harvard University in?
Harvard University refers to university_name = 'Harvard University'; which country refers to country_name
SELECT T2.country_name FROM university AS T1 INNER JOIN country AS T2 ON T1.country_id = T2.id WHERE T1.university_name = 'Harvard University'
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
What is the name of the university with the highest score in teaching in the year 2011?
with the highest score refers to MAX(score); in teaching refers to criteria_name = 'Teaching'; name of university refers to university_name;
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 = 'Teaching' AND T2.year = 2011 ORDER BY T2.score DESC LIMIT 1
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
Please list the names of the universities with a score in teaching of over 90 in 2011.
in 2011 refers to year 2011; in teaching refers to  criteria_name = 'Teaching'; score in teaching of over 90 refers to score > 90; name of university refers to university_name;
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 = 'Teaching' AND T2.year = 2011 AND T2.score > 90
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
Among the universities with a score in teaching of over 90 in 2011, how many of them are in the United States of America?
in 2011 refers to year 2011; in teaching refers to  criteria_name = 'Teaching'; score in teaching of over 90 refers to score > 90; in the United States of America refers to country_name = 'United States of America';
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 T1.criteria_name = 'Teaching' AND T2.year = 2011 AND T2.score > 90
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
Please list the names of all the ranking criteria of Harvard University in 2011.
in 2011 refers to year 2011; Harvard University refers to university_name = 'Harvard University'; names of all the ranking criteria refers to criteria_name
SELECT T1.criteria_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 T3.university_name = 'Harvard University' AND T2.year = 2011
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
What are the names of the universities that got 98 in teaching in 2011?
in 2011 refers to year 2011; that got 98 refers to score = 98; in teaching refers to criteria_name = 'Teaching'; name of university refers to university_name
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 = 'Teaching' AND T2.year = 2011 AND T2.score = 98
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
Please list the names of all the universities that scored under 60 in teaching in 2011 and are in the United States of America.
scored under 60 refers to score < 60; in 2011 refers to year 2011; in teaching refers to criteria_name = 'Teaching'; in the United States of America refers to country_name = 'United States of America';
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 T4.country_name = 'United States of America' AND T2.year = 2011 AND T2.score < 60 AND T1.criteria_name = 'Teaching'
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
Among the universities in Australia, how many of them have a student staff ratio of over 15 in 2011?
in 2011 refers to year 2011; in Australia refers to country_name = 'Australia'; student staff ratio of over 15 refers to student_staff_ratio > 15
SELECT COUNT(*) 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 = 'Australia' AND T2.student_staff_ratio > 15 AND T2.year = 2011
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
How many female students did Stanford University have in 2011?
in 2011 refers to year 2011; female students refers to DIVIDE(MULTIPLY(pct_female_students, num_students), 100); Stanford University refers to university_name = 'Stanford University';
SELECT CAST(T1.num_students * T1.pct_female_students AS REAL) / 100 FROM university_year AS T1 INNER JOIN university AS T2 ON T1.university_id = T2.id WHERE T1.year = 2011 AND T2.university_name = 'Stanford University'
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
Among the universities with a score in teaching of over 90 in 2011, what is the percentage of those in the United States of America?
in 2011 refers to year 2011; in teaching refers to  criteria_name = 'Teaching'; score in teaching of over 90 refers to score > 90; in the United States of America refers to country_name = 'United States of America'; percentage refers to DIVIDE(COUNT(country_name = 'United States of America'), COUNT(id))
SELECT CAST(SUM(CASE WHEN T4.country_name = 'United States of America' THEN 1 ELSE 0 END) AS REAL) * 100 / COUNT(*) AS per 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 = 'Teaching' AND T2.year = 2011 AND T2.score > 90
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
Give the id of "Center for World University Rankings".
"Center for World University Rankings" refers to system_name = 'Center for World University Rankings';
SELECT id FROM ranking_system WHERE system_name = 'Center for World University Rankings'
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
Which country is University of Veterinary Medicine Vienna located in? Give its country id.
University of Veterinary Medicine Vienna refers to university_name = 'University of Veterinary Medicine Vienna';
SELECT country_id FROM university WHERE university_name = 'University of Veterinary Medicine Vienna'
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
What is the id of the criteria "Citations Rank"?
criteria "Citations Rank" refers to criteria_name = 'Citations Rank';
SELECT id FROM ranking_criteria WHERE criteria_name = 'Citations Rank'
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
Show the id of University of Orléans.
University of Orléans refers to university_name = 'University of Orléans';
SELECT id FROM university WHERE university_name = 'University of Orléans'
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
For the university id 268, show its number of students in 2013.
number of students refers to num_students; in 2013 refers to year = 2013
SELECT num_students FROM university_year WHERE university_id = 268 AND year = 2013
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
Show the name of country id 66.
name of country refers to country_name
SELECT country_name FROM country WHERE id = 66
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
Which country is McMaster University located in?
McMaster University refers to university_name = 'McMaster University'; which country refers to country_name
SELECT T2.country_name FROM university AS T1 INNER JOIN country AS T2 ON T1.country_id = T2.id WHERE T1.university_name = 'McMaster University'
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
How many Turkish universities are there in the database?
Turkish universities refers to country_name = 'Turkey';
SELECT COUNT(*) FROM university AS T1 INNER JOIN country AS T2 ON T1.country_id = T2.id WHERE T2.country_name = 'Turkey'
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
Which university had the most students in 2011? Show its name.
in 2011 refers to year 2011; the most students refers to MAX(num_students); which university refers to university_name;
SELECT T2.university_name FROM university_year AS T1 INNER JOIN university AS T2 ON T1.university_id = T2.id WHERE T1.year = 2011 ORDER BY T1.num_students DESC LIMIT 1
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
How many students were there in University of Michigan in 2011?
in 2011 refers to year 2011; in University of Michigan refers to university_name = 'University of Michigan';
SELECT COUNT(*) FROM university AS T1 INNER JOIN university_year AS T2 ON T1.id = T2.university_id WHERE T1.university_name = 'University of Michigan' AND T2.year = 2011
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
For Chosun University, what was its score on "Influence Rank" in 2015?
Chosun University refers to university_name = 'Chosun University'; in 2015 refers to year = 2015; on "Influence Rank" refers to criteria_name = 'Influence Rank';
SELECT T2.score 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 = 'Chosun University' AND T1.criteria_name = 'Influence Rank' AND T2.year = 2015
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
What is the percentage of the international students in University of Oslo in 2015?
percentage of the international students refers to pct_international_students; in 2015 refers to year = 2015; in University of Oslo refers to university_name = 'University of Oslo';
SELECT T2.pct_international_students FROM university AS T1 INNER JOIN university_year AS T2 ON T1.id = T2.university_id WHERE T1.university_name = 'University of Oslo' AND T2.year = 2015
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,
university
For the University of Southampton in 2015, on which criteria did it score the best?
University of Southampton refers to university_name = 'University of Southampton'; in 2015 refers to year = 2015; score the best refers to MAX(score); which criteria refers to criteria_name
SELECT T1.criteria_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 T3.university_name = 'University of Southampton' AND T2.year = 2015 ORDER BY T2.score DESC LIMIT 1
database name:db_id university country table country Cols: id dtype integer, country name dtype text, ranking_system table ranking_system Cols: id dtype integer, system name dtype text, ranking_criteria table ranking_criteria Cols: id dtype integer, ranking system id dtype integer, criteria name dtype text, university table university Cols: id dtype integer, country id dtype integer, university name dtype text, university_ranking_year table university_ranking_year Cols: university id dtype integer, ranking criteria id dtype integer, year dtype integer, score dtype integer, university_year table university_year Cols: university id dtype integer, year dtype integer, number of students dtype integer, student staff ratio dtype real, pct internation student dtype integer, pct female students dtype integer,